Skip to content

Commit 7d6921f

Browse files
chore: Update copier template to v0.5.3
X-Quant-Ranger: copier
1 parent 2c0409a commit 7d6921f

11 files changed

Lines changed: 173 additions & 112 deletions

File tree

.claude/CLAUDE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../AGENTS.md

.copier-answers.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
11
# This file is managed by Copier; DO NOT EDIT OR REMOVE.
2-
_commit: v0.4.1
2+
#
3+
# If you want to change any of the copier answers, run one of the following:
4+
# 1. If you want to answer _all_ questions again:
5+
# `copier update --trust --vcs-ref=:current: .`
6+
# 2. If you want to answer a _specific_ question again:
7+
# `copier update --trust --defaults --vcs-ref=:current: --data answer_name=answer_value .`
8+
#
9+
# If you want to run this as a one-off command, prefix with:
10+
# `pixi exec --spec copier --spec ruamel.yaml -- {command}`
11+
_commit: v0.5.3
312
_src_path: https://github.com/quantco/copier-template-python-open-source
413
add_autobump_workflow: false
514
author_email: noreply@quantco.com
615
author_name: QuantCo, Inc.
716
github_url: https://github.com/quantco/multiregex
817
github_user: pavelzw
9-
minimal_python_version: py39
18+
minimal_python_version: py310
1019
project_short_description: Quickly match many regexes against a string. Provides 2-10x
1120
speedups over naïve regex matching.
1221
project_slug: multiregex

.github/workflows/build.yml

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,42 @@ jobs:
1313
permissions:
1414
contents: read
1515
steps:
16+
<<<<<<< before updating
1617
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
18+
||||||| last update
19+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
20+
=======
21+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
22+
>>>>>>> after updating
1723
with:
1824
fetch-depth: 0
1925
- name: Set up pixi
26+
<<<<<<< before updating
2027
uses: prefix-dev/setup-pixi@5185adfbffb4bd703da3010310260805d89ebb11 # v0.9.6
2128
with:
2229
environments: build
30+
||||||| last update
31+
uses: prefix-dev/setup-pixi@19eac09b398e3d0c747adc7921926a6d802df4da # v0.8.8
32+
with:
33+
environments: build
34+
=======
35+
uses: prefix-dev/setup-pixi@1b2de7f3351f171c8b4dfeb558c639cb58ed4ec0 # v0.9.5
36+
- name: Derive version
37+
id: version
38+
if: startsWith(github.ref, 'refs/tags/')
39+
shell: bash
40+
run: echo "version=$(git describe --tags --abbrev=0 | sed 's/^v//')" >> $GITHUB_OUTPUT
41+
- name: Replace version
42+
if: startsWith(github.ref, 'refs/tags/')
43+
run: |
44+
sed -i -e "s/0.0.0/${STEPS_VERSION_OUTPUTS_VERSION}/g" pyproject.toml
45+
env:
46+
STEPS_VERSION_OUTPUTS_VERSION: ${{ steps.version.outputs.version }}
47+
>>>>>>> after updating
2348
- name: Build project
24-
run: pixi run -e build build-wheel
49+
run: pixi run build-wheel
2550
- name: Check package
26-
run: pixi run -e build check-wheel
51+
run: pixi run check-wheel
2752
- name: Upload package
2853
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
2954
with:

.github/workflows/ci.yml

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,31 @@ permissions:
1414
contents: read
1515

1616
jobs:
17-
pre-commit:
17+
lint:
18+
name: Lint
1819
timeout-minutes: 30
1920
runs-on: ubuntu-latest
2021
steps:
2122
- name: Checkout branch
23+
<<<<<<< before updating
2224
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
25+
||||||| last update
26+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
27+
=======
28+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
29+
>>>>>>> after updating
2330
- name: Set up pixi
31+
<<<<<<< before updating
2432
uses: prefix-dev/setup-pixi@5185adfbffb4bd703da3010310260805d89ebb11 # v0.9.6
25-
with:
26-
environments: default lint
27-
- name: pre-commit
28-
run: pixi run pre-commit-run --color=always --show-diff-on-failure
33+
||||||| last update
34+
uses: prefix-dev/setup-pixi@19eac09b398e3d0c747adc7921926a6d802df4da # v0.8.8
35+
=======
36+
uses: prefix-dev/setup-pixi@1b2de7f3351f171c8b4dfeb558c639cb58ed4ec0 # v0.9.5
37+
>>>>>>> after updating
38+
- name: Run linting
39+
run: pixi run lint
40+
env:
41+
CLICOLOR_FORCE: 1
2942

3043
pytest:
3144
timeout-minutes: 30
@@ -34,25 +47,35 @@ jobs:
3447
fail-fast: false
3548
matrix:
3649
environment:
37-
- py39
3850
- py310
3951
- py311
4052
- py312
4153
- py313
54+
- py314
4255
os:
4356
- ubuntu-latest
4457
- macos-latest
4558
- windows-latest
4659
steps:
4760
- name: Checkout branch
61+
<<<<<<< before updating
4862
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
63+
||||||| last update
64+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
65+
=======
66+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
67+
>>>>>>> after updating
4968
with:
5069
fetch-depth: 0
5170
- name: Set up pixi
71+
<<<<<<< before updating
5272
uses: prefix-dev/setup-pixi@5185adfbffb4bd703da3010310260805d89ebb11 # v0.9.6
73+
||||||| last update
74+
uses: prefix-dev/setup-pixi@19eac09b398e3d0c747adc7921926a6d802df4da # v0.8.8
75+
=======
76+
uses: prefix-dev/setup-pixi@1b2de7f3351f171c8b4dfeb558c639cb58ed4ec0 # v0.9.5
77+
>>>>>>> after updating
5378
with:
5479
environments: ${{ matrix.environment }}
55-
- name: Install repository
56-
run: pixi run -e ${{ matrix.environment }} postinstall
5780
- name: Run pytest
5881
run: pixi run -e ${{ matrix.environment }} test-coverage --color=yes

.github/workflows/scorecard.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,13 @@ jobs:
3535

3636
steps:
3737
- name: "Checkout code"
38+
<<<<<<< before updating
3839
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
40+
||||||| last update
41+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
42+
=======
43+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
44+
>>>>>>> after updating
3945
with:
4046
persist-credentials: false
4147

@@ -74,6 +80,12 @@ jobs:
7480
# Upload the results to GitHub's code scanning dashboard (optional).
7581
# Commenting out will disable upload of results to your repo's Code Scanning dashboard
7682
- name: "Upload to code-scanning"
83+
<<<<<<< before updating
7784
uses: github/codeql-action/upload-sarif@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
85+
||||||| last update
86+
uses: github/codeql-action/upload-sarif@ff0a06e83cb2de871e5a09832bc6a81e7276941f # v3.28.18
87+
=======
88+
uses: github/codeql-action/upload-sarif@9e0d7b8d25671d64c341c19c0152d693099fb5ba # v4.35.5
89+
>>>>>>> after updating
7890
with:
7991
sarif_file: results.sarif

.lefthook.yaml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# yaml-language-server: $schema=https://raw.githubusercontent.com/evilmartians/lefthook/refs/heads/master/schema.json
2+
output: [summary]
3+
templates:
4+
run: run --as-is --quiet --no-progress
5+
no_auto_install: true
6+
pre-commit:
7+
fail_on_changes: always
8+
exclude:
9+
- assets/**/*
10+
jobs:
11+
- name: pixi-install
12+
run: pixi install
13+
- group:
14+
parallel: true
15+
jobs:
16+
- name: ruff-check
17+
glob: "*.{py,pyi}"
18+
run: pixi {run} ruff check --fix --exit-non-zero-on-fix --force-exclude
19+
- name: ruff-format
20+
glob: "*.{py,pyi}"
21+
run: pixi {run} ruff format --force-exclude
22+
- name: mypy
23+
glob: "*.py"
24+
run: pixi {run} mypy {staged_files}
25+
- name: prettier
26+
glob: "*.{md,yml,yaml}"
27+
run: pixi {run} prettier --write --no-error-on-unmatched-pattern --list-different --ignore-unknown {staged_files}
28+
- name: taplo
29+
glob: "*.toml"
30+
run: pixi {run} taplo format {staged_files}
31+
- name: trailing-whitespace-fixer
32+
glob: "*"
33+
file_types: text
34+
run: pixi {run} trailing-whitespace-fixer {staged_files}
35+
- name: end-of-file-fixer
36+
glob: "*"
37+
file_types: text
38+
run: pixi {run} end-of-file-fixer {staged_files}
39+
- name: check-merge-conflict
40+
glob: "*"
41+
file_types: text
42+
run: pixi {run} check-merge-conflict --assume-in-merge {staged_files}
43+
- name: typos
44+
glob: "*"
45+
file_types: text
46+
run: pixi {run} typos --force-exclude {staged_files}
47+
- name: zizmor
48+
glob: "*.{yml,yaml}"
49+
run: pixi {run} zizmor --no-progress --min-severity high --fix --offline .

.pre-commit-config.yaml

Lines changed: 0 additions & 69 deletions
This file was deleted.

AGENTS.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Lockfiles must be consistent with package metadata. After any change to `pixi.toml`, run `pixi lock`.
2+
3+
Everything runs in a pixi environment. Any command (like `pytest`) must be prefixed with `pixi run` (e.g. `pixi run pytest`).
4+
5+
Code formatting must align with our standards. Run `pixi run lint` before `git commit`s to ensure this.

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ git clone https://github.com/quantco/multiregex
2121
cd multiregex
2222

2323
pixi run pre-commit-install
24-
pixi run postinstall
2524
pixi run test
2625
```
2726

0 commit comments

Comments
 (0)