Repository navigation
chore: bring the repository up to canon - #10
Merged
Merged
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The gate bypasses gitleaks whenever CI is nonempty, allowing unscanned commits through because local pre-commit hooks can be skipped or never run.
1 open issue
What changed in this PR
This PR aligns local hooks and workflow execution with the repository’s canon audit requirements.
Changes:
- Adds a pre-push
gatecheck while retaining pre-commit secret scanning. - Cancels superseded copy-sync workflow runs on the same ref.
- Adds a gitleaks gate configured to scan locally and skip scanning when
CIis set.
| File | Description |
|---|---|
lefthook.yml |
Adds the pre-push gate hook. |
.github/workflows/copy-sync.yml |
Adds workflow concurrency and cancellation. |
.gate.toml |
Defines the gitleaks gate with a CI bypass. |
Review effort: Balanced
Comment on lines
+1
to
+5
| # No-op in CI, which never uses --no-verify and already scanned every commit on | ||
| # the way in, so a second scan there spends runner minutes to repeat it. The | ||
| # guard is what keeps one definition serving both hooks. | ||
| [gates.gitleaks] | ||
| run = '[ -n "$CI" ] || gitleaks git --redact --no-banner --log-level warn' |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Fixes the weaker-than-canon items from the Totative canon audit for this repository (each verified first): workflow concurrency with cancel-in-progress and job timeouts (patterns-ci-workflow-00002/00003), canon's lefthook with the pre-push gate (patterns-gitleaks-00003), plus the repository-specific items in the commits. Gate green locally, no rule disabled.