tsc-git-hook / docs /
.tscignore.tscignore guide
.tscignore is the ignore file used by tsc-git-hook during local scans. The CLI loads ignore files recursively and applies them from the repository root down to the scanned file.
Latest stable: 2.0.5 ยท manifest updated: 2026-08-05T00:52:47Z
What works today
- Repository-absolute paths such as
/secrets/local.env. - Recursive discovery of
.tscignorefiles inside the repository. - Additive hierarchy from the repository root down to the candidate file.
- Comments and blank lines.
- Exact file matching for files under the repository root.
The same matching behavior is applied during both pre-push and dry-run scans.
Current limitations
- No globbing.
- No negation rules.
- No directory-only rules.
- No standalone repository detection outside normal CLI execution.
If a path does not match exactly, it will not be ignored.
Example
# Ignore a tracked file
/secrets/local.env
# Ignore a fixture file
/tests/fixtures/github-pat.txt
Operational notes
pre-pushscans only changed files and still respects.tscignorebefore reading content.dry-runscans the current repository view and applies the same ignore filtering.- If all candidates are ignored, the CLI reports that explicitly and exits successfully.
For detector coverage, see the detection catalog.