@event4u/agent-config 1.9.1 → 1.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/.agent-src/commands/agent-handoff.md +15 -0
  2. package/.agent-src/commands/chat-history-clear.md +98 -0
  3. package/.agent-src/commands/chat-history-resume.md +178 -0
  4. package/.agent-src/commands/chat-history.md +102 -0
  5. package/.agent-src/commands/compress.md +9 -9
  6. package/.agent-src/commands/copilot-agents-init.md +1 -1
  7. package/.agent-src/commands/fix-portability.md +2 -2
  8. package/.agent-src/commands/fix-pr-bot-comments.md +1 -1
  9. package/.agent-src/commands/fix-pr-developer-comments.md +1 -1
  10. package/.agent-src/commands/fix-references.md +2 -2
  11. package/.agent-src/commands/mode.md +5 -5
  12. package/.agent-src/commands/onboard.md +171 -0
  13. package/.agent-src/commands/roadmap-create.md +7 -2
  14. package/.agent-src/commands/roadmap-execute.md +2 -2
  15. package/.agent-src/commands/set-cost-profile.md +101 -0
  16. package/.agent-src/commands/sync-agent-settings.md +122 -0
  17. package/.agent-src/commands/sync-gitignore.md +104 -0
  18. package/.agent-src/commands/tests-execute.md +6 -6
  19. package/.agent-src/commands/upstream-contribute.md +5 -4
  20. package/.agent-src/contexts/augment-infrastructure.md +2 -2
  21. package/.agent-src/contexts/override-system.md +1 -1
  22. package/.agent-src/contexts/subagent-configuration.md +3 -3
  23. package/.agent-src/guidelines/agent-infra/layered-settings.md +48 -5
  24. package/.agent-src/rules/ask-when-uncertain.md +56 -3
  25. package/.agent-src/rules/augment-portability.md +52 -1
  26. package/.agent-src/rules/augment-source-of-truth.md +10 -10
  27. package/.agent-src/rules/chat-history.md +171 -0
  28. package/.agent-src/rules/docker-commands.md +5 -7
  29. package/.agent-src/rules/docs-sync.md +13 -9
  30. package/.agent-src/rules/improve-before-implement.md +2 -0
  31. package/.agent-src/rules/onboarding-gate.md +94 -0
  32. package/.agent-src/rules/package-ci-checks.md +6 -5
  33. package/.agent-src/rules/roadmap-progress-sync.md +24 -13
  34. package/.agent-src/rules/size-enforcement.md +1 -1
  35. package/.agent-src/rules/skill-quality.md +1 -1
  36. package/.agent-src/rules/think-before-action.md +1 -0
  37. package/.agent-src/scripts/update_roadmap_progress.py +26 -9
  38. package/.agent-src/skills/check-refs/SKILL.md +1 -1
  39. package/.agent-src/skills/command-routing/SKILL.md +1 -1
  40. package/.agent-src/skills/command-writing/SKILL.md +4 -3
  41. package/.agent-src/skills/file-editor/SKILL.md +2 -2
  42. package/.agent-src/skills/guideline-writing/SKILL.md +4 -3
  43. package/.agent-src/skills/learning-to-rule-or-skill/SKILL.md +2 -2
  44. package/.agent-src/skills/lint-skills/SKILL.md +1 -1
  45. package/.agent-src/skills/roadmap-management/SKILL.md +13 -10
  46. package/.agent-src/skills/rtk-output-filtering/SKILL.md +20 -30
  47. package/.agent-src/skills/rule-writing/SKILL.md +5 -5
  48. package/.agent-src/skills/terragrunt/SKILL.md +0 -8
  49. package/.agent-src/skills/upstream-contribute/SKILL.md +5 -4
  50. package/.agent-src/templates/agent-settings.md +86 -34
  51. package/.claude-plugin/marketplace.json +1 -1
  52. package/AGENTS.md +2 -2
  53. package/CHANGELOG.md +296 -0
  54. package/CONTRIBUTING.md +89 -40
  55. package/README.md +3 -3
  56. package/composer.json +2 -1
  57. package/config/agent-settings.template.yml +45 -6
  58. package/config/gitignore-block.txt +24 -0
  59. package/config/profiles/balanced.ini +5 -0
  60. package/config/profiles/full.ini +5 -0
  61. package/config/profiles/minimal.ini +5 -0
  62. package/docs/customization.md +30 -4
  63. package/docs/getting-started.md +52 -3
  64. package/docs/mcp.md +15 -4
  65. package/package.json +13 -2
  66. package/scripts/agent-config +155 -0
  67. package/scripts/chat_history.py +519 -0
  68. package/scripts/check_portability.py +151 -1
  69. package/scripts/install.py +55 -3
  70. package/scripts/install.sh +50 -21
  71. package/scripts/mcp_render.py +30 -16
  72. package/scripts/release.py +588 -0
  73. package/scripts/sync_agent_settings.py +211 -0
  74. package/scripts/sync_gitignore.py +226 -0
  75. package/templates/agent-config-wrapper.sh +47 -0
  76. package/.agent-src/commands/config-agent-settings.md +0 -126
  77. package/.agent-src/skills/eloquent/evals/last-run.json +0 -99
@@ -0,0 +1,171 @@
1
+ ---
2
+ name: onboard
3
+ description: First-run setup for a developer on this project — captures name, IDE, bot-icon preference, rtk, cost_profile, and learning opt-out, then sets onboarding.onboarded=true
4
+ skills: [file-editor]
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # /onboard
9
+
10
+ Centralized first-run flow. Bundles what used to be scattered "ask once"
11
+ prompts (user_name, IDE, rtk install, cost profile, learning loop) into a
12
+ single interactive setup. Ends by setting `onboarding.onboarded: true` in
13
+ `.agent-settings.yml`.
14
+
15
+ Triggered by the [`onboarding-gate`](../rules/onboarding-gate.md) rule when
16
+ `onboarding.onboarded` is `false` or by the user explicitly re-running it.
17
+
18
+ ## When NOT to use
19
+
20
+ - Change cost profile only → [`/set-cost-profile`](set-cost-profile.md).
21
+ - Single-value edit → ask the agent to change it, or edit
22
+ `.agent-settings.yml` directly. The agent follows the merge rules in
23
+ [`layered-settings`](../guidelines/agent-infra/layered-settings.md).
24
+
25
+ ## Preconditions
26
+
27
+ `.agent-settings.yml` exists. If missing, tell the user to run
28
+ `scripts/install` (or `python3 scripts/install.py`) first and stop — this
29
+ command assumes the file and its template-derived defaults are in place.
30
+
31
+ ## Steps
32
+
33
+ ### 1. Greet and set expectations
34
+
35
+ Keep it short. One line explaining this is the one-time setup, six
36
+ questions, one at a time, following the iron law (`user-interaction`).
37
+
38
+ ### 2. Capture `personal.user_name`
39
+
40
+ Skip if already set (non-empty). Otherwise:
41
+
42
+ ```
43
+ > What first name should I use when talking to you?
44
+ >
45
+ > 1. Type your name
46
+ > 2. Skip — stay anonymous
47
+ ```
48
+
49
+ Free-text answer → write to `personal.user_name`. `2` → leave empty.
50
+
51
+ ### 3. Capture `personal.ide` (with auto-detect)
52
+
53
+ Skip if already set. Otherwise auto-detect first:
54
+
55
+ ```bash
56
+ ps aux | grep -iE '(Visual Studio Code|Code Helper|phpstorm|cursor)' | grep -v grep
57
+ ```
58
+
59
+ - Detected → confirm: `> Detected {ide}. 1. Yes, use it 2. Pick another 3. Skip`.
60
+ - Not detected → ask:
61
+
62
+ ```
63
+ > Which IDE do you use for this project?
64
+ >
65
+ > 1. VS Code (code)
66
+ > 2. PhpStorm (phpstorm)
67
+ > 3. Cursor (cursor)
68
+ > 4. Skip — I'll configure it later
69
+ ```
70
+
71
+ If IDE is set, also ask about `personal.open_edited_files` (`true`/`false`).
72
+
73
+ ### 4. Capture `personal.pr_comment_bot_icon`
74
+
75
+ Personal preference — each developer decides how their own PR replies
76
+ should look. Skip only if the user has already set a non-default value
77
+ deliberately (agent can't tell, so always ask on first run):
78
+
79
+ ```
80
+ > When I reply to PR review comments on your behalf, should I prefix each
81
+ > reply with 🤖 so reviewers can tell it was a bot-authored reply?
82
+ >
83
+ > 1. Yes — prefix replies with 🤖 (transparent to reviewers)
84
+ > 2. No — plain replies, no prefix (default)
85
+ ```
86
+
87
+ `1` → write `personal.pr_comment_bot_icon: true`. `2` → leave `false`.
88
+
89
+ ### 5. Detect `personal.rtk_installed`
90
+
91
+ Silent `which rtk`.
92
+
93
+ - **Found** → write `personal.rtk_installed: true`. No question.
94
+ - **Not found** → ask:
95
+
96
+ ```
97
+ > rtk (Rust Token Killer) is not installed. It cuts verbose CLI output by
98
+ > 60–90% and saves tokens on long test/log/git runs.
99
+ >
100
+ > 1. Install via Homebrew — brew install rtk
101
+ > 2. Install via Cargo — cargo install rtk
102
+ > 3. Skip for now — continue without it
103
+ ```
104
+
105
+ `1` or `2` → run install, on success set `rtk_installed: true` and apply
106
+ rtk post-install steps (telemetry off, init --global) per the
107
+ [`rtk-output-filtering`](../skills/rtk-output-filtering/SKILL.md) skill.
108
+ `3` → leave `rtk_installed: false` and move on. No "ask again tomorrow"
109
+ logic — `/onboard` is one-shot.
110
+
111
+ ### 6. Confirm `cost_profile` and learning loop
112
+
113
+ Read current `cost_profile` and `pipelines.skill_improvement` values.
114
+ Present them plainly (they already have sensible defaults from the
115
+ template — `minimal` + `skill_improvement: true`):
116
+
117
+ ```
118
+ > Cost profile: {current} (minimal by default — includes the learning loop)
119
+ > Learning loop (skill_improvement): {current} (true by default)
120
+ >
121
+ > 1. Keep defaults — recommended
122
+ > 2. Change cost profile — opens /set-cost-profile
123
+ > 3. Disable learning loop — sets pipelines.skill_improvement=false
124
+ ```
125
+
126
+ `2` → defer to `/set-cost-profile` and return here. `3` → flip the toggle.
127
+
128
+ ### 7. Mark onboarded
129
+
130
+ Write `onboarding.onboarded: true` to `.agent-settings.yml` using the
131
+ section-aware merge rules from
132
+ [`layered-settings`](../guidelines/agent-infra/layered-settings.md#section-aware-merge-rules)
133
+ (preserve comments, key order, touch only the changed fields).
134
+
135
+ ### 8. Summary
136
+
137
+ Echo what was captured, in one block:
138
+
139
+ ```
140
+ ✅ Onboarding complete.
141
+
142
+ personal.user_name: {value or —}
143
+ personal.ide: {value or —}
144
+ personal.open_edited_files: {value}
145
+ personal.pr_comment_bot_icon: {value}
146
+ personal.rtk_installed: {value}
147
+ cost_profile: {value}
148
+ pipelines.skill_improvement: {value}
149
+ onboarding.onboarded: true
150
+
151
+ You can re-run this with /onboard anytime, or edit .agent-settings.yml
152
+ directly — the agent follows the merge rules in `layered-settings` when
153
+ you ask it to change a value.
154
+ ```
155
+
156
+ ## Gotchas
157
+
158
+ - `.agent-settings.yml` is git-ignored. This command never commits.
159
+ - One question per turn. The iron law from `ask-when-uncertain` applies;
160
+ do not stack questions 2–6 into a single prompt.
161
+ - Re-running `/onboard` when `onboarded: true` is allowed — walk through
162
+ all steps again and rewrite the values the user confirms.
163
+ - Never overwrite a non-empty value without asking (applies to `user_name`
164
+ and `ide`).
165
+
166
+ ## See also
167
+
168
+ - [`onboarding-gate`](../rules/onboarding-gate.md) — rule that triggers this command
169
+ - [`set-cost-profile`](set-cost-profile.md) — isolated profile change
170
+ - [`layered-settings`](../guidelines/agent-infra/layered-settings.md) — merge rules for mid-life edits
171
+ - [`agent-settings` template](../templates/agent-settings.md) — settings reference
@@ -92,8 +92,13 @@ Show the complete roadmap to the user and ask (in their language) if anything sh
92
92
 
93
93
  ### 7. Update the progress dashboard
94
94
 
95
- Run `task roadmap-progress` so the new roadmap shows up in
96
- `agents/roadmaps-progress.md`. Mention the new overall count to the user.
95
+ Regenerate `agents/roadmaps-progress.md` so the new roadmap shows up:
96
+
97
+ ```bash
98
+ ./agent-config roadmap:progress
99
+ ```
100
+
101
+ Mention the new overall count to the user.
97
102
 
98
103
  ### 8. Offer execution
99
104
 
@@ -44,7 +44,7 @@ For each open step:
44
44
 
45
45
  - Update the roadmap file: mark the completed step (e.g. `[x]` or add a completion note).
46
46
  - Run quality tools if code was changed (PHPStan at minimum).
47
- - Run `task roadmap-progress` so `agents/roadmaps-progress.md` reflects the new state.
47
+ - Regenerate `agents/roadmaps-progress.md` `./agent-config roadmap:progress`.
48
48
  - Ask: "Continue with the next step?"
49
49
 
50
50
  ### 5. After all steps in a phase
@@ -56,7 +56,7 @@ For each open step:
56
56
 
57
57
  - Summarize total progress: steps completed, steps remaining.
58
58
  - Update the roadmap file with the current status.
59
- - Run `task roadmap-progress` one last time so the dashboard matches the final state.
59
+ - Regenerate the dashboard one last time so it matches the final state.
60
60
  - **If ALL steps are done** → trigger the completion & archiving workflow from the `roadmap-management` skill.
61
61
 
62
62
  ### Rules
@@ -0,0 +1,101 @@
1
+ ---
2
+ name: set-cost-profile
3
+ description: Change the cost_profile in .agent-settings.yml — shows each profile's meaning and applies the selection
4
+ skills: [file-editor]
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # /set-cost-profile
9
+
10
+ Changes `cost_profile` in `.agent-settings.yml`. Four profiles are defined in
11
+ the [`agent-settings` template](../templates/agent-settings.md#cost-profiles):
12
+
13
+ - `minimal` · `balanced` · `full` · `custom`
14
+
15
+ `/set-cost-profile` without an argument asks interactively.
16
+ `/set-cost-profile <name>` validates and applies directly.
17
+
18
+ ## When NOT to use
19
+
20
+ - For first-run setup use [`/onboard`](onboard.md).
21
+ - For any other single-value change, edit `.agent-settings.yml`
22
+ directly or ask the agent — the merge rules live in
23
+ [`layered-settings`](../guidelines/agent-infra/layered-settings.md#section-aware-merge-rules).
24
+ - For role modes use [`/mode`](mode.md) — different concept (sets
25
+ `roles.active_role`, not `cost_profile`).
26
+
27
+ ## Steps
28
+
29
+ ### 1. Parse argument
30
+
31
+ - `/set-cost-profile` → interactive (continue with steps 2–5).
32
+ - `/set-cost-profile <name>` → validate `<name>` against the four defined
33
+ profiles. If unknown, refuse and list the valid values.
34
+
35
+ Profile names are case-insensitive on input; the file value stays lowercase.
36
+
37
+ ### 2. Read settings
38
+
39
+ Read `.agent-settings.yml`. If missing, tell the user to run
40
+ `scripts/install` first and stop — do not create the file here.
41
+
42
+ Extract the current `cost_profile` value.
43
+
44
+ ### 3. Load profile descriptions
45
+
46
+ Read `.augment/templates/agent-settings.md` and extract the `## Cost profiles`
47
+ section (table rows). This is the single source of truth for profile
48
+ meanings — do not paraphrase or inline descriptions in this command.
49
+
50
+ ### 4. Show current state and options
51
+
52
+ Render the current value and present numbered choices with the hint text
53
+ extracted in step 3:
54
+
55
+ ```
56
+ > Current: cost_profile = {current}
57
+ >
58
+ > 1. minimal — {hint from template}
59
+ > 2. balanced — {hint from template}
60
+ > 3. full — {hint from template}
61
+ > 4. custom — {hint from template}
62
+ > 5. Keep current — no change
63
+ ```
64
+
65
+ If `<name>` was passed as argument, skip the numbered prompt and use that
66
+ value directly — still echo the old → new line in step 6.
67
+
68
+ ### 5. Write the value
69
+
70
+ Update `cost_profile` in `.agent-settings.yml` using the
71
+ [section-aware merge rules](../guidelines/agent-infra/layered-settings.md#section-aware-merge-rules)
72
+ (preserve comments, preserve key order, touch only the changed field).
73
+
74
+ If the user picked "Keep current", do nothing and stop.
75
+
76
+ ### 6. Confirm
77
+
78
+ ```
79
+ > cost_profile: {old} → {new}
80
+ ```
81
+
82
+ If the new profile activates a surface the user hasn't used before
83
+ (`balanced` adds the runtime dispatcher, `full` adds tool adapters), point
84
+ the user at `docs/customization.md` for setup details — no inline setup
85
+ steps here, that's the docs' job.
86
+
87
+ ## Gotchas
88
+
89
+ - `.agent-settings.yml` is git-ignored. This command never commits the file.
90
+ - Profile names are case-sensitive in the file; case-insensitive on input.
91
+ - The template is the source of truth for descriptions — if it changes,
92
+ this command reflects the new text on next run.
93
+ - `custom` ignores the profile matrix — every per-feature toggle must be
94
+ set explicitly afterwards. Warn the user when switching to `custom`.
95
+
96
+ ## See also
97
+
98
+ - [`agent-settings`](../templates/agent-settings.md) — profile matrix and settings reference
99
+ - [`layered-settings`](../guidelines/agent-infra/layered-settings.md) — merge rules for settings edits
100
+ - [`onboard`](onboard.md) — first-run setup (includes profile confirmation)
101
+ - [`mode`](mode.md) — role-mode setter (different concept)
@@ -0,0 +1,122 @@
1
+ ---
2
+ name: sync-agent-settings
3
+ description: Sync `.agent-settings.yml` against the current template + profile — adds new sections/keys, preserves user values, shows a diff before writing
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ # /sync-agent-settings
8
+
9
+ Reconciles `.agent-settings.yml` with the shipped template
10
+ (`config/agent-settings.template.yml`) and the selected cost-profile
11
+ preset (`config/profiles/{profile}.ini`). Applies the section-aware
12
+ merge rules documented in
13
+ [`layered-settings`](../guidelines/agent-infra/layered-settings.md):
14
+
15
+ - Template section order wins — keys reorder to match.
16
+ - Existing user scalar values are preserved.
17
+ - Missing keys land with their template / profile default.
18
+ - Template comments replace user comments in the same position.
19
+ - Unknown user keys (not in the template) are preserved under a
20
+ trailing `_user:` block so custom additions never vanish silently.
21
+
22
+ Idempotent. Safe to run after every package update.
23
+
24
+ Use when:
25
+
26
+ - A new package version added sections (e.g. `chat_history`,
27
+ `onboarding`) that your local file is missing.
28
+ - A key moved sections (e.g. `pr_comment_bot_icon` from `project` to
29
+ `personal`) and you want the reshuffle applied.
30
+ - You edited the file by hand and want to normalize formatting.
31
+
32
+ ## When NOT to use
33
+
34
+ - To change a value (`ide`, `cost_profile`, `max_parallel`) → edit the
35
+ file directly or ask the agent; the sync only reconciles structure.
36
+ - To create `.agent-project-settings.yml` (team file) → that is a
37
+ separate concern; this command only touches the developer file.
38
+ - To migrate a legacy flat `.agent-settings` → run
39
+ `python3 scripts/install.py` first; the installer owns migrations.
40
+
41
+ ## Steps
42
+
43
+ ### 1. Locate script and target
44
+
45
+ The sync script ships in the installed package. Resolve in order:
46
+
47
+ 1. `./agent-config/scripts/sync_agent_settings.py` — CLI wrapper at the project root.
48
+ 2. `vendor/event4u/agent-config/scripts/sync_agent_settings.py` — Composer.
49
+ 3. `node_modules/@event4u/agent-config/scripts/sync_agent_settings.py` — npm.
50
+
51
+ Target is always `<project_root>/.agent-settings.yml`.
52
+
53
+ ### 2. Dry-run — show the user what would change
54
+
55
+ Run the script with `--dry-run` and capture stdout. Three outcomes:
56
+
57
+ - **No changes** (exit 0, stdout contains `already in sync`) → tell the
58
+ user and stop. No prompt needed.
59
+ ```
60
+ > ✅ .agent-settings.yml already in sync — nothing to do.
61
+ ```
62
+ - **Drift detected** → show the unified diff and ask:
63
+ ```
64
+ > 📝 /sync-agent-settings would update .agent-settings.yml:
65
+ >
66
+ > {diff}
67
+ >
68
+ > 1. Apply — write the changes
69
+ > 2. Skip — leave the file untouched
70
+ ```
71
+ - **Script error** (exit 2, e.g. template or profile missing) → print
72
+ the error and stop; do not prompt.
73
+
74
+ ### 3. Act on the choice
75
+
76
+ - `1` (Apply) → re-run the script **without** `--dry-run`. Confirm:
77
+ ```
78
+ > ✅ .agent-settings.yml updated.
79
+ ```
80
+ Then re-run with `--check` to confirm idempotency.
81
+ - `2` (Skip) → stop. No changes made.
82
+
83
+ Free-text replies (`"nö"`, `"leave it"`, unrecognized input) count as
84
+ `2`. Never write on ambiguous input.
85
+
86
+ ### 4. Profile override
87
+
88
+ The script auto-detects the profile from the target's `cost_profile`
89
+ key and falls back to `minimal`. To sync against a different profile
90
+ (e.g. during a profile change), pass `--profile balanced` or
91
+ `--profile full` — but ask the user first; changing the profile is a
92
+ separate decision from reconciling structure.
93
+
94
+ ## `--check` mode
95
+
96
+ `sync_agent_settings.py --check` exits **2** if the file is out of
97
+ sync, **0** otherwise — suitable for CI. Emit no diff prompt in
98
+ check-only workflows; report the drift and let the pipeline decide.
99
+
100
+ ## Gotchas
101
+
102
+ - **Unknown keys end up under `_user:`.** They are not deleted, but the
103
+ user should review and either upstream them (propose a template key)
104
+ or remove them. The block carries a comment explaining this.
105
+ - **Bare lowercase identifiers stay unquoted** (`per_turn`, `rotate`,
106
+ `phpstorm`). Everything else (names, paths, empty strings) stays
107
+ quoted. That is intentional — idempotency depends on it.
108
+ - **Comments from the template win.** If you added a note above a key,
109
+ the sync replaces it with the template comment. Put notes in a
110
+ separate file if you need them to survive syncs.
111
+ - Changes to `config/agent-settings.template.yml` or the profile
112
+ presets require a package update in the consumer project before
113
+ this command can apply them.
114
+
115
+ ## See also
116
+
117
+ - [`scripts/sync_agent_settings.py`](../../../scripts/sync_agent_settings.py) — the helper
118
+ - [`config/agent-settings.template.yml`](../../../config/agent-settings.template.yml) — canonical template
119
+ - [`config/profiles/`](../../../config/profiles/) — profile presets
120
+ - [`layered-settings`](../guidelines/agent-infra/layered-settings.md) — the merge rules this command enforces
121
+ - [`scripts/install.py`](../../../scripts/install.py) — first-install path; this command handles the update path
122
+ - [`/sync-gitignore`](sync-gitignore.md) — sibling command for the `.gitignore` block
@@ -0,0 +1,104 @@
1
+ ---
2
+ name: sync-gitignore
3
+ description: Sync the `event4u/agent-config` block in the consumer project's .gitignore — adds missing entries, preserves user-added lines, shows a diff before writing
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ # /sync-gitignore
8
+
9
+ Ensures the consumer project's `.gitignore` contains every entry the
10
+ package expects to be ignored (symlinked `.augment/` subdirectories,
11
+ `/agent-config` CLI wrapper, `.agent-settings*`, `.agent-chat-history*`).
12
+ Canonical list lives in `config/gitignore-block.txt`; the same file
13
+ drives the installer, so the two cannot drift.
14
+
15
+ Use when:
16
+
17
+ - A fresh package version added new managed entries and the installer
18
+ has not been re-run yet.
19
+ - The project's `.gitignore` never got the block (older install, manual
20
+ setup, or installer ran with `--skip-gitignore`).
21
+ - You want to audit what the block **should** look like without writing.
22
+
23
+ ## When NOT to use
24
+
25
+ - To disable logging or change what is logged → that is
26
+ `chat_history.enabled` in `.agent-settings.yml`, not `.gitignore`.
27
+ - To delete the block entirely → do it by hand; the package will not
28
+ re-remove its own entries.
29
+ - To change what the block contains → edit
30
+ `config/gitignore-block.txt` in the package repo and re-release.
31
+
32
+ ## Steps
33
+
34
+ ### 1. Locate script and target
35
+
36
+ The sync script ships in the installed package. Resolve in order:
37
+
38
+ 1. `./agent-config/scripts/sync_gitignore.py` — if the CLI wrapper
39
+ directory exists at the project root.
40
+ 2. `vendor/event4u/agent-config/scripts/sync_gitignore.py` — Composer.
41
+ 3. `node_modules/@event4u/agent-config/scripts/sync_gitignore.py` — npm.
42
+
43
+ Target is always `<project_root>/.gitignore`. If no `.gitignore` exists,
44
+ stop and tell the user — the package does not create one unilaterally:
45
+
46
+ ```
47
+ > 📝 No .gitignore found at <project_root>. Create one first (e.g. `touch .gitignore`), then re-run /sync-gitignore.
48
+ ```
49
+
50
+ ### 2. Dry-run — show the user what would change
51
+
52
+ Run the script with `--dry-run` and capture stdout. Three outcomes:
53
+
54
+ - **No changes** (exit 0, stdout says "already in sync") → tell the
55
+ user and stop. No prompt needed.
56
+ ```
57
+ > ✅ .gitignore already in sync — nothing to do.
58
+ ```
59
+ - **Additions only** (default append-only mode) → show the unified
60
+ diff and ask:
61
+ ```
62
+ > 📝 /sync-gitignore would add {N} entr{y|ies} to .gitignore:
63
+ >
64
+ > {diff}
65
+ >
66
+ > 1. Apply — write the changes
67
+ > 2. Skip — leave .gitignore untouched
68
+ ```
69
+ - **Script error** (exit 2, e.g. template missing) → print the error
70
+ and stop; do not prompt.
71
+
72
+ ### 3. Act on the choice
73
+
74
+ - `1` (Apply) → re-run the script **without** `--dry-run`. Confirm:
75
+ ```
76
+ > ✅ .gitignore updated ({N} entries added).
77
+ ```
78
+ - `2` (Skip) → stop. No changes made.
79
+
80
+ Free-text replies (`"nö"`, `"leave it"`, unrecognized input) count as
81
+ `2`. Never write on ambiguous input.
82
+
83
+ ### 4. Offer `--replace` only when asked
84
+
85
+ Do **not** suggest `--replace` by default. It rewrites the block in
86
+ full and drops user-added lines inside the block — destructive.
87
+ Mention it only if the user explicitly asks to clean up or reset the
88
+ block, and confirm once more before running it.
89
+
90
+ ## Gotchas
91
+
92
+ - The script honors the explicit `# event4u/agent-config — END` marker.
93
+ Legacy blocks without it get the marker added automatically on the
94
+ first sync — that is expected, not a bug.
95
+ - User-added lines **inside** the block survive append-only syncs.
96
+ They do not survive `--replace`.
97
+ - Changes to `config/gitignore-block.txt` require a package update in
98
+ the consumer project before this command can apply them.
99
+
100
+ ## See also
101
+
102
+ - [`scripts/sync_gitignore.py`](../../../scripts/sync_gitignore.py) — the helper
103
+ - [`config/gitignore-block.txt`](../../../config/gitignore-block.txt) — canonical block body
104
+ - [`scripts/install.sh`](../../../scripts/install.sh) — installer integration (same source of truth, `--skip-gitignore` to opt out)
@@ -14,13 +14,13 @@ disable-model-invocation: true
14
14
  Check in this order — use the **first match**:
15
15
 
16
16
  1. **Makefile** exists → look for test targets (`make test`, `make test-unit`, etc.)
17
- 2. **Taskfile.yml** exists → look for test tasks (`task test`, `task test-unit`, etc.)
18
- 3. **`artisan` exists** → Laravel project → `php artisan test`
19
- 4. **`vendor/bin/pest` exists** → Pest → `vendor/bin/pest`
20
- 5. **Fallback** → PHPUnit → `vendor/bin/phpunit`
17
+ 2. **`artisan` exists**Laravel project `php artisan test`
18
+ 3. **`vendor/bin/pest` exists** → Pest → `vendor/bin/pest`
19
+ 4. **Fallback**PHPUnit → `vendor/bin/phpunit`
21
20
 
22
- **Prefer Makefile/Taskfile targets** over raw commands — they handle container access,
23
- environment variables, and parallel settings automatically.
21
+ **Prefer Makefile targets** over raw commands — they handle container access,
22
+ environment variables, and parallel settings automatically. If the project
23
+ uses a different task runner, inspect its config before falling back to raw.
24
24
 
25
25
  ### 2. Run the tests
26
26
 
@@ -115,10 +115,11 @@ Frontmatter must have `source: package`.
115
115
  ### 6. Run quality gates
116
116
 
117
117
  ```bash
118
- task lint-skills # 0 FAIL required
119
- task check-compression # No 🔴 errors for this file
120
- task generate-tools # Regenerate symlinks
121
- task consistency # Everything clean
118
+ python3 scripts/skill_linter.py --all # 0 FAIL required
119
+ python3 scripts/check_compression.py # No 🔴 errors for this file
120
+ python3 scripts/compress.py --generate-tools # Regenerate symlinks
121
+ bash scripts/compress.sh --check # .agent-src/ in sync with source
122
+ bash scripts/compress.sh --check-hashes # All hashes match
122
123
  ```
123
124
 
124
125
  Fix any issues before continuing.
@@ -68,7 +68,7 @@ Define hard constraints: coding standards, Docker usage, language preferences, s
68
68
  | `rtk.md` | Using rtk for token-efficient CLI output filtering |
69
69
  | `agent-docs.md` | When to read/create/update documentation |
70
70
  | `augment-portability.md` | Everything in `.augment/` must be project-agnostic |
71
- | `roadmap-progress-sync.md` | Checkbox edits in `agents/roadmaps/*.md` must trigger `task roadmap-progress` in the same response |
71
+ | `roadmap-progress-sync.md` | Checkbox edits in `agents/roadmaps/*.md` must regenerate `agents/roadmaps-progress.md` in the same response |
72
72
 
73
73
  ### Skills (`.augment/skills/`)
74
74
 
@@ -113,7 +113,7 @@ Commands organized by workflow:
113
113
  | **E2E** | `e2e-plan`, `e2e-heal` |
114
114
  | **Agents** | `agents-prepare`, `agents-audit`, `agents-cleanup`, `copilot-agents-optimize`, `agent-handoff`, `agent-status`, `optimize-agents`, `optimize-augmentignore`, `optimize-skills`, `optimize-rtk-filters` |
115
115
  | **Overrides** | `override-create`, `override-manage` |
116
- | **Config** | `config-agent-settings`, `commit` |
116
+ | **Config** | `onboard`, `set-cost-profile`, `commit` |
117
117
  | **Packages** | `package-test`, `package-reset` |
118
118
  | **Project** | `project-analyze`, `project-health`, `jira-ticket` |
119
119
 
@@ -149,7 +149,7 @@ When a project using this package wants to **optimize** a shared rule or skill:
149
149
 
150
150
  - The PR must contain **both** uncompressed and compressed versions (complete files)
151
151
  - The compressed version must be derived from the uncompressed version
152
- - Changes must pass the skill linter (`task lint-skills`)
152
+ - Changes must pass the skill linter (`python3 scripts/skill_linter.py --all`)
153
153
  - Changes must not be project-specific (no domain assumptions)
154
154
  - Changes must pass the promotion gate (see `controlled-self-optimization.md`)
155
155
 
@@ -51,9 +51,9 @@ completes a multi-step task 2-3x faster than serial at ~2x the cost.
51
51
 
52
52
  ## When settings change
53
53
 
54
- The `/config-agent-settings` command detects changes and re-resolves
55
- on next invocation. There is no long-running process to restart — the
56
- commands read `.agent-settings.yml` on each run.
54
+ Edits to `.agent-settings.yml` (manual or via the agent) take effect
55
+ on the next invocation there is no long-running process to restart.
56
+ The commands read `.agent-settings.yml` fresh on each run.
57
57
 
58
58
  ## Related
59
59