gitignore: ignore ltp-agent setup files
PATCH v3 1/1 gitignore: ignore ltp-agent setup files
From: Andrea Cervesato <[email protected]>
The ltp-agent tool injects a number of files and symlinks into the LTP working directory at runtime (AGENTS.md, GEMINI.md, .agents, .claude, and the agents/, linter/ and skills/ symlinks pointing at the agent data). These are local helpers used by the agent and must never be tracked or committed.
Directory entries for the injected symlinks are anchored to the repository root (leading '/') and have no trailing slash, so they match the ltp-agent symlinks without shadowing any unrelated subdirectory of the same name.
Also ignore a few local agent working files: the /.pi/ session directory and review-inline.txt scratch files.
---
Changes in v3:
- add .pi and review file
- Link to v2: https://lore.kernel.org/r/[email protected]
Changes in v2:
- fix files shadowing
- Link to v1: https://lore.kernel.org/r/[email protected]
--- .gitignore | 13 +++++++++++++ 1 file changed, 13 insertions(+)
.gitignore +13 -0
@@ -63,3 +63,16 @@ compile_commands.json # added by scripts/checkpatch.pl .checkpatch-camelcase.* + +# ltp-agent setup +AGENTS.md +GEMINI.md +.agents +.claude +/agents +/linter +/skills + +# agents files +/.pi/ +review-inline.txt
---
base-commit: 5ccf816f5d0e6c0ec3d808be456dd9ffa2a7736d
change-id: 20260530-gitignore_ltp_agent-0c7c137b6156
Best regards,
Signature · 5 lines
Andrea Cervesato <[email protected]> -- Mailing list info: https://lists.linux.it/listinfo/ltp
Hi Andrea,
Generally LGTM.
Quoted 10 lines
The ltp-agent tool injects a number of files and symlinks into the LTP working directory at runtime (AGENTS.md, GEMINI.md, .agents, .claude, and the agents/, linter/ and skills/ symlinks pointing at the agent data). These are local helpers used by the agent and must never be tracked or committed.
Directory entries for the injected symlinks are anchored to the repository root (leading '/') and have no trailing slash, so they match the ltp-agent symlinks without shadowing any unrelated subdirectory of the same name.
Out of curiosity, here you talk about /agents /linters and /skills, right?
.gitignore compile_commands.json · line 67
Quoted 13 lines
Also ignore a few local agent working files: the /.pi/ session directory and review-inline.txt scratch files.
.gitignore +2
-0@@ -63,3 +63,16 @@ compile_commands.json # added by scripts/checkpatch.pl .checkpatch-camelcase.* + +# ltp-agent setup
Maybe link the agent project to make it obviou
# https://github.com/linux-test-project/ltp-agent
.gitignore compile_commands.json · line 71
Quoted 4 lines
.gitignore +4
-0+AGENTS.md +GEMINI.md +.agents +.claude
I wonder shouldn't all the above have leading '/' (slash)? OK to change before merge.
.gitignore compile_commands.json · line 76
Quoted 5 lines
.gitignore +5
-0+/agents +/linter +/skills + +# agents files
What is the difference between "files" and "setup"?
.gitignore compile_commands.json · line 78
Quoted 2 lines
.gitignore +2
-0+/.pi/ +review-inline.txt
And here as well leading slash?
Kind regards,
Petr
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
Hi Petr,
Quoted 11 lines
Hi Andrea,
Generally LGTM.
Reviewed-by Petr Vorel <[email protected]>Quoted 5 lines
The ltp-agent tool injects a number of files and symlinks into the LTP working directory at runtime (AGENTS.md, GEMINI.md, .agents, .claude, and the agents/, linter/ and skills/ symlinks pointing at the agent data). These are local helpers used by the agent and must never be tracked or committed.
Quoted 6 lines
Quoted 4 lines
Directory entries for the injected symlinks are anchored to the repository root (leading '/') and have no trailing slash, so they match the ltp-agent symlinks without shadowing any unrelated subdirectory of the same name.
Out of curiosity, here you talk about /agents /linters and /skills, right?
Yes
Quoted 10 lines
Quoted 9 lines
Also ignore a few local agent working files: the /.pi/ session directory and review-inline.txt scratch files.
.gitignore +0
-0@@ -63,3 +63,16 @@ compile_commands.json
Quoted 6 lines
.gitignore compile_commands.json · line 67
Quoted 4 lines
.gitignore +2
-0# added by scripts/checkpatch.pl .checkpatch-camelcase.* + +# ltp-agent setupMaybe link the agent project to make it obviou
# https://github.com/linux-test-project/ltp-agent
I will add it
Quoted 7 lines
.gitignore compile_commands.json · line 71
Quoted 5 lines
.gitignore +4
-0+AGENTS.md +GEMINI.md +.agents +.claudeI wonder shouldn't all the above have leading '/' (slash)? OK to change before merge.
Sure
Quoted 7 lines
.gitignore compile_commands.json · line 76
Quoted 6 lines
.gitignore +5
-0+/agents +/linter +/skills + +# agents filesWhat is the difference between "files" and "setup"?
I wanted to split ltp-agent stuff from generic agents usage such as pi (https://pi.dev/) and spurious files produced by ltp-review skill.
Quoted 4 lines
.gitignore compile_commands.json · line 78
Quoted 3 lines
.gitignore +2
-0+/.pi/ +review-inline.txtAnd here as well leading slash?
good idea indeed
Quoted 4 lines
Kind regards,
Petr
--
Andrea Cervesato
SUSE QE Automation Engineer Linux
[email protected]
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
Hi!
Signature · 5 lines
Cyril Hrubis [email protected] -- Mailing list info: https://lists.linux.it/listinfo/ltp
Hi Andrea,
Quoted 1 line · Andrea Cervesato
gitignore: ignore ltp-agent setup files
Infrastructure-only patch (.gitignore only) — code review checklist skipped per protocol.
COMMIT MESSAGE
--------------
The subject follows <area>: <description> format with imperative mood.
The body accurately enumerates the injected artefacts: AGENTS.md, GEMINI.md, .agents, .claude, and the agents/, linter/, skills/ symlinks.
The rationale for root-anchoring /agents, /linter, and /skills with a leading '/' and no trailing slash is correct:
- Leading '/' prevents shadowing same-named subdirectories deeper in the tree (e.g. a hypothetical testcases/foo/agents/).
- Omitting the trailing slash is necessary because these are symlinks; a trailing slash in .gitignore only matches real directories, not symlinks, so the entries would silently fail to suppress them without it.
/.pi/ correctly uses both a root anchor and a trailing slash (actual directory, not a symlink).
PATCH CORRECTNESS
-----------------
All nine added entries map 1:1 to the artefacts described in the body. The two comment headers ("# ltp-agent setup" and "# agents files") cleanly separate the injected runtime artefacts from the scratch working files.
The unanchored entries (.agents, .claude, review-inline.txt, AGENTS.md, GEMINI.md) lack a leading '/'. This makes them match anywhere in the tree, not just at the root. For .agents and .claude this is a slight overshoot compared to the anchored treatment of /agents, /linter, /skills, but the commit body does not claim these are anchored. In practice, no test code creates .agents or .claude subdirectories, so no false suppression is expected. This is noted for completeness but does not require a fix.
Verdict: Reviewed ✓
LTP AI Reviewer
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
Andrea Cervesato via ltp
AppliedMerged, Thanks!
--
Andrea Cervesato
SUSE QE Automation Engineer Linux
[email protected]
Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp