Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .claude/settings.local.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"permissions": {
"allow": [
"Bash(find:*)"
],
"deny": [],
"ask": []
}
}
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Please describe your changes clearly and concisely.

**Checklist:**

- [ ] I have followed the [coding conventions](https://amoccommunity.github.io/amocarray/conventions.html).
- [ ] I have followed the [coding conventions](docs/source/conventions.md).
- [ ] I have updated or added tests to cover my changes.
- [ ] I have updated the documentation if needed.
- [ ] I have run `pytest` to check that all tests pass.
Expand Down
57 changes: 30 additions & 27 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,40 +6,43 @@ on:
- '**.py'
- '**.ipynb'
- '**.rst'
- '**.md'

jobs:
build-docs:
runs-on: ubuntu-latest
permissions:
contents: write
contents: read

steps:
- name: checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Micromamba ${{ matrix.python-version }}
uses: mamba-org/setup-micromamba@v2.0.1
with:
environment-name: TEST
init-shell: bash
create-args: >-
python=3 pip
--file requirements-dev.txt
--channel conda-forge
- name: Setup Micromamba
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment.yml
init-shell: bash
condarc: |
channels:
- conda-forge
channel_priority: strict
cache-environment: true

- name: Install seagliderOG1
shell: bash -l {0}
run: |
python -m pip install -e . --no-deps --force-reinstall
- name: Install package (editable)
shell: bash -l {0}
run: |
micromamba run -n TEST python -m pip install --upgrade pip
micromamba run -n TEST python -m pip install -e . --no-deps --force-reinstall

- name: Build documentation
shell: bash -l {0}
run: |
set -e
jupyter nbconvert --to notebook --execute notebooks/demo.ipynb --output=demo-output.ipynb --ExecutePreprocessor.allow_errors=True
mv notebooks/*output.ipynb docs/source/
pushd docs
make clean html
popd
- name: Build documentation
shell: bash -l {0}
run: |
set -e
micromamba run -n TEST jupyter nbconvert --to notebook --execute notebooks/demo.ipynb --output=demo-output.ipynb --ExecutePreprocessor.allow_errors=True
mv notebooks/*output.ipynb docs/source/
pushd docs
micromamba run -n TEST make clean html
popd
70 changes: 36 additions & 34 deletions .github/workflows/docs_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,48 +4,50 @@ on:
push:
branches:
- main
# Optional: manual trigger
workflow_dispatch:

jobs:
build-docs:
deploy-docs:
runs-on: ubuntu-latest
permissions:
contents: write

steps:
- name: Run a one-line script
run: echo "The job was automatically triggered by a ${{ github.event_name }} event."
- name: checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Micromamba ${{ matrix.python-version }}
uses: mamba-org/setup-micromamba@v2.0.1
with:
environment-name: TEST
init-shell: bash
create-args: >-
python=3 pip
--file requirements-dev.txt
--channel conda-forge
- name: Setup Micromamba
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment.yml
init-shell: bash
condarc: |
channels:
- conda-forge
channel_priority: strict
cache-environment: true

- name: Install seagliderOG1
shell: bash -l {0}
run: |
python -m pip install -e . --no-deps --force-reinstall
- name: Install package (editable)
shell: bash -l {0}
run: |
micromamba run -n TEST python -m pip install --upgrade pip
micromamba run -n TEST python -m pip install -e . --no-deps --force-reinstall

- name: Build documentation
shell: bash -l {0}
run: |
set -e
jupyter nbconvert --to notebook --execute notebooks/demo.ipynb --output=demo-output.ipynb --ExecutePreprocessor.allow_errors=True
mv notebooks/*output.ipynb docs/source/
pushd docs
make clean html
popd
- name: Build documentation
shell: bash -l {0}
run: |
set -e
micromamba run -n TEST jupyter nbconvert --to notebook --execute notebooks/demo.ipynb --output=demo-output.ipynb --ExecutePreprocessor.allow_errors=True
mv notebooks/*output.ipynb docs/source/
pushd docs
micromamba run -n TEST make clean html
popd

- name: Deploy
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build/html
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build/html
59 changes: 31 additions & 28 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,42 +15,45 @@ on:
- '**.ipynb'

jobs:
job_mytests:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ["3.10", "3.12"]
fail-fast: true
defaults:
run:
shell: bash -l {0}
steps:
- name: Run a one-line script
run: echo "The job was automatically triggered by a ${{ github.event_name }} event."
- uses: actions/checkout@v4

- name: Setup Micromamba Python ${{ matrix.python-version }}
uses: mamba-org/setup-micromamba@v2
with:
environment-name: TEST
init-shell: bash
create-args: >-
python=${{ matrix.python-version }} --file requirements-dev.txt --channel conda-forge
env:
MAMBA_NO_BANNER: true
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Check Package Installation
run: |
micromamba env list
micromamba list
python -m pip check
- name: Setup Micromamba
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment.yml
init-shell: bash
condarc: |
channels:
- conda-forge
channel_priority: strict
cache-environment: true
create-args: >-
python=${{ matrix.python-version }}

- name: Check Package Installation
shell: bash -l {0}
run: |
micromamba run -n TEST micromamba env list
micromamba run -n TEST micromamba list
micromamba run -n TEST python -m pip check

- name: Install seagliderOG1
run: |
python -m pip install -e . --no-deps --force-reinstall
- name: Install package (editable)
shell: bash -l {0}
run: |
micromamba run -n TEST python -m pip install --upgrade pip
micromamba run -n TEST python -m pip install -e . --no-deps --force-reinstall

- name: Full Tests
run: |
python -m pytest --cov=seagliderOG1 --cov-report term-missing tests/
- name: Run tests
shell: bash -l {0}
run: |
micromamba run -n TEST python -m pytest --cov=seagliderOG1 --cov-report term-missing tests/
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -172,3 +172,4 @@ de421.bsp

# Claude Code files
CLAUDE.md
.claude/*.json
Loading
Loading