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
9 changes: 5 additions & 4 deletions template/.pre-commit-config.yaml.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,13 @@ repos:
- id: pretty-format-yaml
args: [--autofix, --offset, '2']
exclude: ^\.copier-answers\.yml$
- repo: https://github.com/gitleaks/gitleaks
rev: v8.30.1
hooks:
- id: gitleaks
- repo: local
hooks:
- id: betterleaks
name: betterleaks
entry: betterleaks git . --pre-commit --staged --redact
language: system
pass_filenames: false
- id: ruff
name: ruff
entry: uv run ruff check --fix
Expand Down
6 changes: 6 additions & 0 deletions template/mise.toml.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ postinstall = [
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -73,6 +74,11 @@ run = [
description = "Create and push a release tag (patch/minor/major)"
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"
{%- if "syrupy" in enable_features %}

[tasks.snapup]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ jobs:
run: mise run docs-build
{%- endif %}

gitleaks:
betterleaks:
name: Secret scan
runs-on: ubuntu-latest
permissions:
Expand All @@ -102,8 +102,12 @@ jobs:
with:
fetch-depth: 0

- name: 馃嵆 Set up mise
uses: jdx/mise-action@v4
with:
cache: true
install: true

- name: 馃攳 Check for secrets
uses: gitleaks/gitleaks-action@v2
env:
GITHUB_TOKEN: {% raw %}${{ secrets.GITHUB_TOKEN }}{% endraw %}
run: mise run secretscan
{#- vim: set ft=yaml: #}
96 changes: 96 additions & 0 deletions tests/template/__snapshots__/test_mise_toml.ambr
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -63,6 +64,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -126,6 +132,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -186,6 +193,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -249,6 +261,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -288,6 +301,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -351,6 +369,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -397,6 +416,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -460,6 +484,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -513,6 +538,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -581,6 +611,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -641,6 +672,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -709,6 +745,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -748,6 +785,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -816,6 +858,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -862,6 +905,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -930,6 +978,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -983,6 +1032,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -1046,6 +1100,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1106,6 +1161,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -1169,6 +1229,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1208,6 +1269,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -1271,6 +1337,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1317,6 +1384,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.test]
description = "Run tests"
raw_args = true
Expand Down Expand Up @@ -1380,6 +1452,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1433,6 +1506,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -1501,6 +1579,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1561,6 +1640,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -1629,6 +1713,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1668,6 +1753,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down Expand Up @@ -1736,6 +1826,7 @@
]

[tools]
betterleaks = "latest"
"pipx:copier" = "latest"
prek = "latest"
uv = "latest"
Expand Down Expand Up @@ -1782,6 +1873,11 @@
raw_args = true
run = "uv run bump-my-version bump -v"

[tasks.secretscan]
description = "Scan git history for secrets"
raw_args = true
run = "betterleaks git . --redact"

[tasks.snapup]
description = "Update test snapshots"
raw_args = true
Expand Down
Loading
Loading