Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ repos:
- id: trailing-whitespace

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.16.10"
rev: "v0.17.0"
hooks:
- id: ruff-check
args: ["--fix"]
Expand Down Expand Up @@ -53,19 +53,19 @@ repos:
- types-PyYAML

- repo: https://github.com/rbubley/mirrors-prettier
rev: "v3.9.9"
rev: "v3.9.10"
hooks:
- id: prettier
types_or: [yaml, html, css, scss, javascript, json]

- repo: https://github.com/rvben/rumdl-pre-commit
rev: "v0.2.78"
rev: "v0.2.79"
hooks:
- id: rumdl
args: [--no-exclude] # Disable all exclude patterns

- repo: https://github.com/crate-ci/typos
rev: "v1.50.3"
rev: "v1.51.1"
hooks:
- id: typos
exclude: ^Gemfile\.lock$
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/gha_basic.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ tests:
allow-prereleases: true

- name: Download uv
uses: astral-sh/setup-uv@v10.2.0
uses: astral-sh/setup-uv@v10.3.0

- name: Test package
run: uv run pytest
Expand Down
6 changes: 3 additions & 3 deletions docs/guides/gha_wheels.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ make_sdist:
with:
fetch-depth: 0 # Optional, use if you use setuptools_scm
submodules: true # Optional, use if you have submodules
- uses: astral-sh/setup-uv@v10.2.0
- uses: astral-sh/setup-uv@v10.3.0

- name: Build SDist
run: uv build --sdist
Expand Down Expand Up @@ -113,9 +113,9 @@ build_wheels:
fetch-depth: 0
submodules: true

- uses: astral-sh/setup-uv@v10.2.0
- uses: astral-sh/setup-uv@v10.3.0

- uses: pypa/cibuildwheel@v4.2
- uses: pypa/cibuildwheel@v4.3

- name: Upload wheels
uses: actions/upload-artifact@v7
Expand Down
20 changes: 10 additions & 10 deletions docs/guides/style.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ Here is the snippet to add the formatter to your `.pre-commit-config.yml`

```yaml
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.16.10"
rev: "v0.17.0"
hooks:
# id: ruff-check would go here if using both
- id: ruff-format
Expand Down Expand Up @@ -176,7 +176,7 @@ Here is the snippet to add Black to your `.pre-commit-config.yml`:

```yaml
- repo: https://github.com/psf/black-pre-commit-mirror
rev: "26.10.0"
rev: "26.10.1"
hooks:
- id: black
```
Expand Down Expand Up @@ -216,7 +216,7 @@ your code and your docs. Add `markdown` to the `ruff-format` hook's `types_or`:

```yaml
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.16.10"
rev: "v0.17.0"
hooks:
- id: ruff-format
types_or: [python, pyi, jupyter, markdown, pyproject]
Expand Down Expand Up @@ -256,7 +256,7 @@ pre-commit hook.

```yaml
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.16.10"
rev: "v0.17.0"
hooks:
- id: ruff-check
args: ["--fix", "--show-fixes"]
Expand Down Expand Up @@ -591,7 +591,7 @@ when clearly better (please always use them, they are faster) if you set

```yaml
- repo: https://github.com/asottile/pyupgrade
rev: "v3.21.2"
rev: "v3.22.0"
hooks:
- id: pyupgrade
args: ["--py39-plus"]
Expand Down Expand Up @@ -672,7 +672,7 @@ with `additional_dependencies`, and pass extra flags via `args`.
:sync: ty
```yaml
- repo: https://github.com/astral-sh/ty-pre-commit
rev: "v0.0.84"
rev: "v0.0.86"
hooks:
- id: ty
```
Expand Down Expand Up @@ -857,7 +857,7 @@ important parts (like Python classifiers) are in sync. This tool,

```yaml
- repo: https://github.com/asottile/setup-cfg-fmt
rev: "v3.2.0"
rev: "v3.3.0"
hooks:
- id: setup-cfg-fmt
args: [--include-version-classifiers, --max-py-version=3.12]
Expand Down Expand Up @@ -907,7 +907,7 @@ integration.

```yaml
- repo: https://github.com/crate-ci/typos
rev: "v1.50.3"
rev: "v1.51.1"
hooks:
- id: typos
args: []
Expand Down Expand Up @@ -988,7 +988,7 @@ following pre-commit config:

```yaml
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: "v23.1.2"
rev: "v23.1.3"
hooks:
- id: clang-format
types_or: [c++, c, cuda]
Expand Down Expand Up @@ -1017,7 +1017,7 @@ number of different file types. An example of usage:

```yaml
- repo: https://github.com/rbubley/mirrors-prettier
rev: "v3.9.9"
rev: "v3.9.10"
hooks:
- id: prettier
types_or: [yaml, markdown, html, css, scss, javascript, json]
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/tasks.md
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ You can install `uv` with `pipx`, `brew`, etc. If you want to use uv in GitHub
Actions, one way is to use this:

```yaml
- uses: astral-sh/setup-uv@v10.2.0
- uses: astral-sh/setup-uv@v10.3.0
```

Check your jobs with `uv`; most things do not need to change. The main
Expand Down
4 changes: 2 additions & 2 deletions helpers/extensions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import datetime
import datetime as dt
from collections.abc import Mapping

from copier_templates_extensions import ContextHook
Expand Down Expand Up @@ -39,7 +39,7 @@ class CookiecutterContext(SmartDict):

@CookiecutterContext.register
def __year(_):
return str(datetime.datetime.now(tz=datetime.UTC).year)
return str(dt.datetime.now(tz=dt.UTC).year)


@CookiecutterContext.register
Expand Down
4 changes: 2 additions & 2 deletions {{cookiecutter.project_name}}/.github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
with:
python-version: "3.x"

- uses: astral-sh/setup-uv@v10.2.0
- uses: astral-sh/setup-uv@v10.3.0

- uses: j178/prek-action@v2

Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
python-version: {% raw %}${{ matrix.python-version }}{% endraw %}
allow-prereleases: true

- uses: astral-sh/setup-uv@v10.2.0
- uses: astral-sh/setup-uv@v10.3.0

{%- if cookiecutter.backend == "mesonpy" %}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,12 @@ jobs:
persist-credentials: false
fetch-depth: 0

- uses: astral-sh/setup-uv@v10.2.0
- uses: astral-sh/setup-uv@v10.3.0
with:
# Disable caching to avoid poisoning published wheels
enable-cache: false

- uses: pypa/cibuildwheel@v4.2
- uses: pypa/cibuildwheel@v4.3

- name: Upload wheels
uses: actions/upload-artifact@v7
Expand Down
6 changes: 3 additions & 3 deletions {{cookiecutter.project_name}}/.pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,14 @@ repos:
- id: rst-inline-touching-normal

- repo: https://github.com/rbubley/mirrors-prettier
rev: "v3.9.9"
rev: "v3.9.10"
hooks:
- id: prettier
types_or: [yaml, markdown, html, css, scss, javascript, json]
args: [--prose-wrap=always]

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.16.10"
rev: "v0.17.0"
hooks:
- id: ruff-check
args: ["--fix"]
Expand All @@ -47,7 +47,7 @@ repos:
{%- if cookiecutter.backend in ["pybind11", "skbuild", "mesonpy"] %}

- repo: https://github.com/pre-commit/mirrors-clang-format
rev: "v23.1.2"
rev: "v23.1.3"
hooks:
- id: clang-format
types_or: [c++, c, cuda]
Expand Down
Loading