-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* update packaging( * move cli * un example during tests * typo * lint and format * run test by default with tox * drop python 3.7 and test on 3.12 * rely on hacthling vcs for versioning * use pyproject for codespell config * add load to init * bump action version * add other packages for testing
- Loading branch information
Showing
25 changed files
with
345 additions
and
169 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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 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 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,53 @@ | ||
--- | ||
name: update precommit hooks | ||
|
||
|
||
on: | ||
|
||
# Uses the cron schedule for github actions | ||
# | ||
# https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#scheduled-events | ||
# | ||
# ┌───────────── minute (0 - 59) | ||
# │ ┌───────────── hour (0 - 23) | ||
# │ │ ┌───────────── day of the month (1 - 31) | ||
# │ │ │ ┌───────────── month (1 - 12 or JAN-DEC) | ||
# │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT) | ||
# │ │ │ │ │ | ||
# │ │ │ │ │ | ||
# │ │ │ │ │ | ||
# * * * * * | ||
schedule: | ||
- cron: 0 0 1 1,4,7,10 * # every 3 months | ||
|
||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
jobs: | ||
update_precommit_hooks: | ||
|
||
# only run on upstream repo | ||
if: github.repository_owner == 'neuropower' | ||
|
||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.12' | ||
allow-prereleases: false | ||
- name: Install pre-commit | ||
run: pip install pre-commit | ||
- name: Update pre-commit hooks | ||
run: pre-commit autoupdate | ||
- name: Create Pull Request | ||
uses: peter-evans/create-pull-request@v6 | ||
with: | ||
commit-message: pre-commit hooks auto-update | ||
base: main | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
delete-branch: true | ||
title: '[BOT] update pre-commit hooks' | ||
body: done via this [GitHub Action](https://github.com/${{ github.repository_owner }}/neurodesign/blob/master/.github/workflows/update_precommit_hooks.yml) |
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 |
---|---|---|
@@ -1,11 +1,24 @@ | ||
*.bak | ||
|
||
build/* | ||
*egg*/* | ||
dist/* | ||
.DS_Store | ||
|
||
.vscode | ||
|
||
*egg*/* | ||
*.pyc | ||
build/ | ||
dist/ | ||
|
||
env/ | ||
venv/ | ||
|
||
# handled by hatch | ||
nidmresults/_version.py | ||
|
||
*.nidm.zip | ||
|
||
test/data | ||
debug.log | ||
|
||
test/data | ||
|
||
.tox |
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,73 @@ | ||
--- | ||
# See https://pre-commit.com for more information | ||
# See https://pre-commit.com/hooks.html for more hooks | ||
|
||
repos: | ||
# - repo: https://github.com/pre-commit/pre-commit-hooks | ||
# rev: v4.5.0 | ||
# hooks: | ||
# - id: check-ast | ||
# - id: check-case-conflict | ||
# - id: check-json | ||
# - id: check-merge-conflict | ||
# - id: check-toml | ||
# - id: check-yaml | ||
# - id: end-of-file-fixer | ||
# - id: mixed-line-ending | ||
# - id: trailing-whitespace | ||
|
||
# - repo: https://github.com/pycqa/isort | ||
# rev: 5.13.2 | ||
# hooks: | ||
# - id: isort | ||
# args: [--profile, black, --settings-path, pyproject.toml] | ||
|
||
# - repo: https://github.com/asottile/pyupgrade | ||
# rev: v3.15.0 | ||
# hooks: | ||
# - id: pyupgrade | ||
# args: [--py38-plus] | ||
|
||
# - repo: https://github.com/psf/black-pre-commit-mirror | ||
# rev: 24.1.1 | ||
# hooks: | ||
# - id: black | ||
# args: [--config, pyproject.toml] | ||
|
||
# - repo: https://github.com/adamchainz/blacken-docs | ||
# rev: 1.16.0 | ||
# hooks: | ||
# - id: blacken-docs | ||
# additional_dependencies: | ||
# - black==23.9.1 | ||
|
||
- repo: https://github.com/codespell-project/codespell | ||
rev: v2.2.6 | ||
hooks: | ||
- id: codespell | ||
args: [--toml, pyproject.toml] | ||
additional_dependencies: [tomli] | ||
|
||
# - repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt | ||
# rev: 0.2.3 | ||
# hooks: | ||
# - id: yamlfmt | ||
# args: [--mapping, '4', --sequence, '4', --offset, '0'] | ||
|
||
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks | ||
rev: v2.12.0 | ||
hooks: | ||
- id: pretty-format-toml | ||
args: [--autofix, --indent, '4'] | ||
|
||
# - repo: https://github.com/pre-commit/pygrep-hooks | ||
# rev: v1.10.0 | ||
# hooks: | ||
# - id: rst-backticks | ||
|
||
# - repo: https://github.com/pyCQA/flake8 | ||
# rev: 7.0.0 | ||
# hooks: | ||
# - id: flake8 | ||
# args: [--config, .flake8, --verbose, nilearn, examples, maint_tools] | ||
# additional_dependencies: [flake8-docstrings, flake8-use-fstring, flake8-functions] |
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.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 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 |
---|---|---|
@@ -1,10 +1,11 @@ | ||
import os | ||
from pkg_resources import get_distribution | ||
|
||
from .load import load | ||
from nidmresults.load import load | ||
|
||
from nidmresults._version import __version__ | ||
|
||
latest_owlfile = os.path.join( | ||
os.path.dirname(os.path.dirname(__file__)), 'nidmresults', 'owl', | ||
"nidm-results_130.owl") | ||
|
||
__version__ = get_distribution('nidmresults').version | ||
__all__ = ["load"] |
Empty file.
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
Oops, something went wrong.