| name | configure-gitattributes |
| description | Configure .gitattributes: union-merge for append-only tables, linguist-generated for build output, LF normalization. Use when setting up .gitattributes or taming append-only merge conflicts. |
| args | [--check-only] [--fix] |
| argument-hint | [--check-only] [--fix] |
| allowed-tools | Glob, Grep, Read, Write, Edit, Bash(git add *), Bash(git status *), Bash(git diff *), Bash(git check-attr *), Bash(find *), Bash(test *), AskUserQuestion, TodoWrite |
| created | "2026-06-22T00:00:00.000Z" |
| modified | "2026-06-22T00:00:00.000Z" |
| reviewed | "2026-06-22T00:00:00.000Z" |
/configure:gitattributes
Audit or create a repo's .gitattributes, applying the three high-value
attributes — merge=union for append-only tables, linguist-generated for
build output, and LF normalization — while never applying merge=union to a
file it would corrupt. See .claude/rules/gitattributes.md for the convention.
When to Use This Skill
| Use this skill when... | Use another approach when... |
|---|
A repo has no .gitattributes and wants the standard baseline | Changing a single setting in an existing file — edit it directly |
| Parallel PRs keep conflicting on an append-only table/changelog | The conflict is semantic (same line edited) — that needs a real merge |
Onboarding a repo (also reachable via /configure:repo) | Configuring Claude Code settings — use /configure:repo |
| Build output (changelogs, lockfiles, generated trees) clutters PR diffs | — |
Context
- Existing attributes: !
find . -maxdepth 1 -name .gitattributes -type f
- Shell scripts present: !
find . -name '*.sh' -not -path '*/.git/*' -path '*/scripts/*'
- Changelogs: !
find . -name 'CHANGELOG.md' -not -path '*/.git/*'
- Generated trees: !
find . -type d -name generated -not -path '*/.git/*'
- Rendered diagrams: !
find . -path '*/docs/diagrams/*' -name '*.svg'
- Lockfiles: !
find . -maxdepth 3 \( -name 'uv.lock' -o -name 'bun.lock' -o -name 'package-lock.json' -o -name 'pnpm-lock.yaml' \)
Parameters
| Parameter | Description |
|---|
--check-only | Report the proposed additions without writing any file |
--fix | Apply the safe (zero-risk) additions without prompting |
Default (no flag): propose the additions, write them, and git add the file (staged, not committed).
Execution
Execute this .gitattributes configuration workflow: