forked from gallantlab/pycortex
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'gallantlab/main'
- Loading branch information
Showing
75 changed files
with
1,147 additions
and
979 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# For more configuration details: | ||
# https://docs.codecov.io/docs/codecov-yaml | ||
|
||
# Check if this file is valid by running in bash: | ||
# curl -X POST --data-binary @.codecov.yml https://codecov.io/validate | ||
|
||
# Coverage configuration | ||
# ---------------------- | ||
coverage: | ||
status: | ||
project: | ||
default: | ||
threshold: 1% # complain if change in codecoverage is greater than 1% | ||
patch: false | ||
range: 70..90 # First number represents red, and second represents green | ||
# (default is 70..100) | ||
round: down # up, down, or nearest | ||
precision: 2 # Number of decimal places, between 0 and 5 | ||
|
||
|
||
# Ignoring Paths | ||
# -------------- | ||
# which folders/files to ignore | ||
# ignore: | ||
# - */tests/.* | ||
# - setup.py | ||
|
||
# Pull request comments: | ||
# ---------------------- | ||
# Diff is the Coverage Diff of the pull request. | ||
# Files are the files impacted by the pull request | ||
comment: false | ||
# layout: diff, files # accepted in any order: reach, diff, flags, and/or files |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "github-actions" # See documentation for possible values | ||
directory: "/" # Location of package manifests | ||
schedule: | ||
interval: "weekly" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Build docs | ||
|
||
on: | ||
push: | ||
pull_request: | ||
|
||
jobs: | ||
build-docs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip- | ||
- name: Install dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y inkscape | ||
pip install --upgrade pip | ||
pip install wheel numpy "cython<3.0" pillow | ||
pip install -q ipython Sphinx sphinx-gallery numpydoc | ||
pip install -e . --no-build-isolation | ||
python -c 'import cortex; print(cortex.__full_version__)' | ||
- name: Build documents | ||
run: | | ||
cd docs && make html && cd .. | ||
touch docs/_build/html/.nojekyll | ||
- name: Publish to gh-pages if tagged | ||
if: startsWith(github.ref, 'refs/tags') | ||
uses: JamesIves/github-pages-deploy-action@v4.4.3 | ||
with: | ||
branch: gh-pages | ||
folder: docs/_build/html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
name: Codespell | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
codespell: | ||
name: Check for spelling errors | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Codespell | ||
uses: codespell-project/actions-codespell@v2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
name: Install from wheel | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
jobs: | ||
install-from-wheel: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: [3.9] | ||
max-parallel: 5 | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip- | ||
- name: Install dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y inkscape | ||
pip install --upgrade pip | ||
pip install wheel numpy "cython<3.0" | ||
- name: Create the wheel | ||
run: python setup.py bdist_wheel | ||
|
||
- name: Install from the wheel | ||
run: | | ||
pip install $(ls dist/*.whl) --no-build-isolation | ||
- name: Test installation of the filestore | ||
run: | | ||
# change directory to avoid conflict with cortex directory | ||
cd .. | ||
python -c 'import cortex; print(cortex.db.filestore)' | ||
python -c 'from cortex.webgl.view import cmapdir; print(cmapdir)' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: Build and publish to PyPI if tagged | ||
on: push | ||
jobs: | ||
build-n-publish: | ||
name: Build and publish to PyPI if tagged | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
- name: Install pypa/build | ||
run: >- | ||
python -m | ||
pip install | ||
build | ||
- name: Build a source tarball | ||
run: >- | ||
python -m | ||
build | ||
--sdist | ||
--outdir dist/ | ||
- name: Publish distribution to PyPI | ||
if: startsWith(github.ref, 'refs/tags') | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
password: ${{ secrets.PYPI_API_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Run tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
jobs: | ||
run-tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: [3.7, 3.8, 3.9, "3.10"] | ||
max-parallel: 5 | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip- | ||
- name: Install dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y inkscape | ||
pip install --upgrade pip | ||
pip install wheel numpy "cython<3.0" | ||
# force using latest nibabel | ||
pip install -U nibabel | ||
pip install -e . --no-build-isolation | ||
python -c 'import cortex; print(cortex.__full_version__)' | ||
- name: Test with pytest | ||
run: | | ||
pip install -q pytest pytest-cov codecov | ||
pytest --cov=./ | ||
- name: Run codecov | ||
run: | | ||
codecov |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.