Skip to content

Commit

Permalink
MAINT: update lock files (#46)
Browse files Browse the repository at this point in the history
* FIX: group pre-commit hooks
* FIX: set correct ignore patterns for `sphinx-autobuild`
* MAINT: remove dynamic version from `uv.lock`
* MAINT: update developer environment
  • Loading branch information
grayson-helmholz authored Jan 29, 2025
1 parent 12e1ef8 commit b3fdba4
Show file tree
Hide file tree
Showing 6 changed files with 225 additions and 199 deletions.
9 changes: 5 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ repos:
- id: check-useless-excludes

- repo: https://github.com/ComPWA/policy
rev: 0.5.10
rev: 0.6.1
hooks:
- id: check-dev-files
args:
Expand All @@ -21,6 +21,7 @@ repos:
- --repo-title="STRONG2020 HaSP School"
- id: colab-toc-visible
- id: remove-empty-tags
- id: set-nb-display-name

- repo: https://github.com/kynan/nbstripout
rev: 0.8.1
Expand Down Expand Up @@ -51,7 +52,7 @@ repos:
metadata.vscode
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.6
rev: v0.9.3
hooks:
- id: ruff
args: [--fix]
Expand Down Expand Up @@ -88,7 +89,7 @@ repos:
- --in-place

- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: 3.0.3
rev: 3.2.0
hooks:
- id: editorconfig-checker
name: editorconfig
Expand All @@ -99,6 +100,6 @@ repos:
)$
- repo: https://github.com/astral-sh/uv-pre-commit
rev: 0.5.16
rev: 0.5.25
hooks:
- id: uv-lock
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
},
"notebook.formatOnSave.enabled": true,
"notebook.gotoSymbols.showAllSymbols": true,
"python.defaultInterpreterPath": ".venv/bin/python",
"python.terminal.activateEnvironment": false,
"redhat.telemetry.enabled": false,
"rewrap.wrappingColumn": 88,
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ git clone https://github.com/ComPWA/strong2020-salamanca
cd strong2020-salamanca
```

Now it's simply a matter of creating and activating the [virtual environment](https://docs.astral.sh/uv/pip/environments) with [`uv sync`](https://docs.astral.sh/uv/reference/cli/#uv-sync). The dependencies for the project are 'pinned' in each commit through the [`uv.lock` file](https://docs.astral.sh/uv/concepts/projects/#project-lockfile).
Now it's simply a matter of creating and activating the [virtual environment](https://docs.astral.sh/uv/pip/environments) with [`uv sync`](https://docs.astral.sh/uv/reference/cli/#uv-sync). The dependencies for the project are 'pinned' in each commit through the [`uv.lock` file](https://docs.astral.sh/uv/concepts/projects/layout/#the-lockfile).

```shell
uv sync --all-extras
Expand Down
2 changes: 1 addition & 1 deletion docs/lecture24/utilities.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
"toc_visible": true
},
"kernelspec": {
"display_name": "Python 3",
"display_name": "Pyproject Local",
"name": "pyproject_local_kernel"
},
"language_info": {
Expand Down
36 changes: 30 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ commands = [
"--keep-going",
"--show-traceback",
"docs/",
"docs/_build/html",
"docs/_build/html/",
],
]
description = "Build documentation as website"
Expand All @@ -190,11 +190,35 @@ allowlist_externals = ["sphinx-autobuild"]
commands = [
[
"sphinx-autobuild",
"--ignore=docs/_build/",
"--open-browser",
"--watch=docs",
"--port=0",
"--re-ignore=/__pycache__(/.*)?$",
"--re-ignore=/_build(/.*)?$",
"--re-ignore=/_images(/.*)?$",
"--re-ignore=/\\.cache(/.*)?$",
"--re-ignore=/\\.egg-info(/.*)?$",
"--re-ignore=/\\.ipynb_checkpoints(/.*)?$",
"--re-ignore=/\\.venv(/.*)?$",
"--re-ignore=/\\.virtual_documents(/.*)?$",
"--re-ignore=/api(/.*)?$",
"--re-ignore=/docs$",
"--re-ignore=/version\\.py$",
"--re-ignore=\\.csv$",
"--re-ignore=\\.egg-info(/.*)?$",
"--re-ignore=\\.gif$",
"--re-ignore=\\.gitignore$",
"--re-ignore=\\.gv$",
"--re-ignore=\\.inv$",
"--re-ignore=\\.json$",
"--re-ignore=\\.pickle$",
"--re-ignore=\\.pkl$",
"--re-ignore=\\.png$",
"--re-ignore=\\.root$",
"--re-ignore=\\.svg$",
"--re-ignore=\\.tmp$",
"--re-ignore=\\.txt$",
"--re-ignore=\\.ya?ml$",
"docs/",
"docs/_build/html",
"docs/_build/html/",
],
]
description = "Set up a server to directly preview changes to the HTML pages"
Expand Down Expand Up @@ -232,7 +256,7 @@ commands = [
"--builder=linkcheck",
"--show-traceback",
"docs/",
"docs/_build/linkcheck",
"docs/_build/linkcheck/",
],
]
description = "Check external links in the documentation (requires internet connection)"
Expand Down
Loading

0 comments on commit b3fdba4

Please sign in to comment.