Codex Merge Repository Gitignore Patterns and Verify Their Scope
Compose a repository `.gitignore` from language and tooling patterns plus confirmed generated files.
中文Install in Codex
Use a local Git repository and current ignore rules. Fetching optional external templates requires its networking tools.
- Copy the pinned `skills/setup-gitignore/` directory into `.agents/skills/setup-gitignore/` in the project.
- Have Codex read `references/LANGUAGE-DETECTION.md` and the bundled patterns, and list candidate local rules first.
Example task
In a local fixture with an existing `.gitignore`, add `build-cache/`. Compare a generated file under it and a root-level `example.json` with Git status and check-ignore.What to check
The cache matches the new rule, `example.json` stays visible, and a second run adds no duplicate pattern.
Original SKILL.md on GitHub · Updated
Frequently asked question
Do new ignore patterns automatically untrack files?
Git ignore patterns primarily affect untracked files. An already tracked file's repository state requires a separate action.