@ethlete/agent-rules 0.1.0-next.17 → 0.1.0-next.18

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 (44) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/README.md +9 -2
  3. package/content/hooks/subagent-model-policy.py +5 -3
  4. package/content/rules/subagent-models.md +7 -7
  5. package/content/skills/design-exploration/SKILL.md +3 -1
  6. package/content/skills/query/SKILL.md +3 -2
  7. package/content/skills/timetrack/SKILL.md +97 -27
  8. package/package.json +1 -1
  9. package/src/lib/frontmatter.js +32 -5
  10. package/src/lib/frontmatter.js.map +1 -1
  11. package/src/lib/git-flow/parse.js +38 -12
  12. package/src/lib/git-flow/parse.js.map +1 -1
  13. package/src/lib/git-flow-repair.js +12 -1
  14. package/src/lib/git-flow-repair.js.map +1 -1
  15. package/src/lib/git.js +8 -2
  16. package/src/lib/git.js.map +1 -1
  17. package/src/lib/gitlab.js +11 -1
  18. package/src/lib/gitlab.js.map +1 -1
  19. package/src/lib/migrate.js +1 -1
  20. package/src/lib/migrate.js.map +1 -1
  21. package/src/lib/output-style.js +11 -3
  22. package/src/lib/output-style.js.map +1 -1
  23. package/src/lib/owned-paths.js +8 -2
  24. package/src/lib/owned-paths.js.map +1 -1
  25. package/src/lib/plan.js +20 -4
  26. package/src/lib/plan.js.map +1 -1
  27. package/src/lib/render.d.ts +4 -0
  28. package/src/lib/render.js +8 -2
  29. package/src/lib/render.js.map +1 -1
  30. package/src/lib/sync.js +3 -0
  31. package/src/lib/sync.js.map +1 -1
  32. package/src/lib/targets/codex.js +1 -1
  33. package/src/lib/targets/codex.js.map +1 -1
  34. package/src/lib/targets/copilot.js +1 -1
  35. package/src/lib/targets/copilot.js.map +1 -1
  36. package/src/lib/targets/git-hooks.js +2 -1
  37. package/src/lib/targets/git-hooks.js.map +1 -1
  38. package/src/lib/targets/hooks-shared.js +1 -1
  39. package/src/lib/targets/hooks-shared.js.map +1 -1
  40. package/src/lib/timetrack-command.js +255 -68
  41. package/src/lib/timetrack-command.js.map +1 -1
  42. package/src/lib/timetrack.d.ts +125 -23
  43. package/src/lib/timetrack.js +53 -17
  44. package/src/lib/timetrack.js.map +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # @ethlete/agent-rules
2
2
 
3
+ ## 0.1.0-next.18
4
+
5
+ ### Minor Changes
6
+
7
+ - Timetrack: every write command now queues for the user's approval in the app and prints an approval id; `timetrack approval <id>` reads the outcome, and the agent contract moves to version 3.
8
+ - Timetrack: add `timetrack sync <day>` to plan a day's Tempo sync, and `--write --plan <hash>` to write the confirmed plan; `worklogs --json` now reports a midnight `startTime`.
9
+ - Timetrack: add `timetrack worklog --delete <id> --day <YYYY-MM-DD>` to delete one of the account's own Tempo worklogs; the app refuses any other id.
10
+ - Timetrack: add `timetrack standins --merge <id> --into <id>` and the `standIn.merge` agent op, which waits for the user's approval. `standIn.list` now reports `hiddenOn` and `mergedIds`.
11
+
12
+ ### Patch Changes
13
+
14
+ - `parseBranch` now reads a leading issue key from a deprecated spelling such as `dev-FIP-2721-subject`, so it returns the key and a rename suggestion that carries it.
15
+ - The design exploration skill now tells an agent in the ethlete SDK that the user reads calls in Ethlete Studio (`yarn studio`), so the agent does not start `yarn design` next to it.
16
+ - Git-flow matches a project key prefix as a whole word, keeps the subject with a grouped `keyPattern`, drops the `CI_JOB_TOKEN` fallback, and prints an undo hint when the push after a repair rename fails.
17
+ - `git-flow repair` sends `GITLAB_TOKEN` only to the hosts in `GITLAB_HOST` or `CI_SERVER_HOST`, and no longer follows redirects.
18
+ - `git-flow repair` and `start` no longer mistake a remote branch that only ends with the name, such as `team/feat/x` for `feat/x`, for the branch.
19
+ - `sync` writes only changed files, survives dangling symlinks, warns about an unparseable hook settings file, and rejects duplicate frontmatter keys; `output-style --remove` works for a style no longer shipped.
20
+ - `timetrack` rejects a flag whose value is another flag, a malformed `naming` day and a non-positive `--limit`; `day --out` honours `--json` and resolves against the root.
21
+ - `timetrack` reads a date-only `--at`, `--from` or `--to` as local midnight and accepts a local `HH:MM`, and `timetrack project` resolves a relative path.
22
+ - `sync` refuses a file whose ethlete marker block has lost a marker, instead of deleting the text after it on the next run.
23
+ - Git flow: a lowercase `<word>-<number>` branch subject such as `step-2-rework` is no longer read as an issue key when no key prefixes are configured.
24
+ - `tableSortQueryField()` holds the `et-table` sort and keeps it in the URL, so `[(sort)]="qf.fields.sort().value"` binds it with no mapping.
25
+ - Recommend `sonnet` for scoped subagent work and keep `opus` for hard work, in the subagent-models rule and the subagent-model-policy hook.
26
+
3
27
  ## 0.1.0-next.17
4
28
 
5
29
  ### Minor Changes
package/README.md CHANGED
@@ -224,7 +224,8 @@ sets no subject falls back to its summary, and the printed plan says which of th
224
224
  `git-flow repair [ref]` derives the conforming name (`--key FIP-2900` when the old name
225
225
  carries no issue key, `--to <branch>` to override), renames the branch locally and on the
226
226
  remote, and retargets the open merge requests aimed at it through the GitLab API.
227
- `GITLAB_TOKEN` needs the `api` scope.
227
+ `GITLAB_TOKEN` needs the `api` scope, and is sent only to the hosts named in `GITLAB_HOST`
228
+ (comma-separated) or, in a GitLab CI job, `CI_SERVER_HOST`.
228
229
 
229
230
  Everything is checked before the first mutation, and it refuses rather than half-finishing:
230
231
 
@@ -232,7 +233,7 @@ Everything is checked before the first mutation, and it refuses rather than half
232
233
  move a merge request to another source branch, and closing it would lose its discussion -
233
234
  merge or close it first.
234
235
  - A branch that is pushed but whose merge requests cannot be listed (no token, or a remote
235
- that is not GitLab) blocks too. `--no-mr-check` asserts that none point at it.
236
+ that is not a configured GitLab host) blocks too. `--no-mr-check` asserts that none point at it.
236
237
  - If a retarget fails halfway, the old branch is still there and the recovery commands are
237
238
  printed.
238
239
 
@@ -248,10 +249,16 @@ npx ethlete-agents timetrack search "password" # open issues of the picked p
248
249
  npx ethlete-agents timetrack project # which project does this repo log into?
249
250
  npx ethlete-agents timetrack create --summary "…" # file a ticket with the instance's settings
250
251
  npx ethlete-agents timetrack log --issue FIP-2177 --minutes 45
252
+ npx ethlete-agents timetrack approval <id> # where a queued write stands
251
253
  ```
252
254
 
253
255
  `--json` prints the raw answer instead of lines. `git-flow start` uses the same channel.
254
256
 
257
+ **Every write waits for the user.** `create`, `log` and every other write answer at once with an
258
+ approval id and write nothing; the user approves or rejects the request in the app, and
259
+ `approval <id>` reads the outcome. A request still waiting at the end of its day expires.
260
+ `TIMETRACK_CLIENT` names the caller in the queue.
261
+
255
262
  **How it connects.** The app binds a loopback socket and writes its port and a fresh token
256
263
  into `agent.json` in its own data directory (`~/.local/share/io.ethlete.timetrack/` on Linux,
257
264
  `~/Library/Application Support/…` on macOS, `%APPDATA%\…` on Windows), readable by its owner
@@ -43,8 +43,10 @@ would run on the model leading this session - which is how one expensive model e
43
43
  Call the tool again with `model` set:
44
44
 
45
45
  - `haiku` - mechanical lookups: grep, find, read a file, run a command and report what it said.
46
- - `opus` - the default for real work: code changes, tests, debugging, reviewing a diff.
47
- - `sonnet` - a middle ground where opus is more than the task needs.
46
+ - `sonnet` - scoped work with a clear target: a fix in a named file, a spec, a docs page, a lint cleanup, \
47
+ research that needs reasoning. Sonnet 5.5 is close to opus here and costs less.
48
+ - `opus` - hard work: a bug with no known cause, a change across many files, a review of a diff, and any task \
49
+ sonnet did not finish.
48
50
  - `fable` - judgment-heavy work: planning, design, cross-cutting review, leading other subagents. The most \
49
51
  expensive of the four, so choosing it asks the user first.
50
52
 
@@ -54,7 +56,7 @@ effort, so a call that names one needs no `model` of its own."""
54
56
 
55
57
  FABLE_REASON = """This subagent would run on fable, the most expensive model. Approve it where the task is \
56
58
  judgment-heavy - planning, design, cross-cutting review, or leading other subagents. Deny it for implementation \
57
- (`model: "opus"`) or for a mechanical lookup (`model: "haiku"`), then repeat the call with that model."""
59
+ (`model: "sonnet"` or `"opus"`) or for a mechanical lookup (`model: "haiku"`), then repeat the call with that model."""
58
60
 
59
61
 
60
62
  def agent_name(argv):
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: subagent-models
3
- description: A subagent's model is an explicit choice on every call - haiku for lookups, opus for work, fable for judgment.
3
+ description: A subagent's model is an explicit choice on every call - haiku for lookups, sonnet for scoped work, opus for hard work, fable for judgment.
4
4
  kind: rule
5
5
  scope: both
6
6
  ---
@@ -11,12 +11,12 @@ A subagent spawned without a `model` runs on the model leading the session, so a
11
11
  model ends up doing every small job it delegates. **Set `model` on every call**, matched to the
12
12
  task:
13
13
 
14
- | Model | The work it fits |
15
- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
16
- | `haiku` | Mechanical lookups: grep, find, read a file, run a command and report what it said. |
17
- | `sonnet` | A middle ground where opus is more than the task needs. |
18
- | `opus` | The default for real work: code changes, tests, debugging, reviewing a diff. |
19
- | `fable` | Judgment-heavy work: planning, design, cross-cutting review, leading other subagents. The most expensive of the four, so ask the user before picking it. |
14
+ | Model | The work it fits |
15
+ | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
16
+ | `haiku` | Mechanical lookups: grep, find, read a file, run a command and report what it said. |
17
+ | `sonnet` | Scoped work with a clear target: a fix in a named file, a spec, a docs page, a lint cleanup, research that needs reasoning. Sonnet 5.5 is close to opus here and costs less. |
18
+ | `opus` | Hard work: a bug with no known cause, a change across many files, a review of a diff, and any task sonnet did not finish. |
19
+ | `fable` | Judgment-heavy work: planning, design, cross-cutting review, leading other subagents. The most expensive of the four, so ask the user before picking it. |
20
20
 
21
21
  Effort follows the prompt, not a parameter: scope the prompt to one question, name what "done"
22
22
  means, and say "keep it brief" for a lookup. Two calls need no `model` of their own - a named
@@ -67,7 +67,9 @@ drawings. A project the config names not draws bare.
67
67
  Start the page with `et design [checkout]`, which serves the port `config.json` names. The
68
68
  checkout defaults to the working directory, and `DE_PORT` overrules the config, so two
69
69
  checkouts can be drawn at once. A repository that builds the tool rather than installing it
70
- wraps this in a script - in the ethlete SDK, `yarn design` and `yarn design:check`.
70
+ wraps this in a script - in the ethlete SDK, `yarn design:check`. There, the user reads the
71
+ calls in Ethlete Studio, started with `yarn studio`, and Studio serves the page itself. Do not
72
+ start `yarn design` next to it.
71
73
 
72
74
  Ethlete Studio carries its own copy of the tool, so it draws a checkout that installs nothing.
73
75
  The machine still needs Node, and the render stage still needs `playwright` where the copy in
@@ -123,7 +123,7 @@ post = computed(() => this.postQuery.response());
123
123
  - `GET`/`HEAD`/`OPTIONS` **auto-execute** - immediately when static/argless, or
124
124
  whenever `withArgs` produces new args. Mutations (`POST`/`PUT`/`PATCH`/`DELETE`)
125
125
  never auto-execute; declare their args with `withArgs` too and call `.execute()`. A function route (`pathParams`)
126
- requires `withArgs` (dev-mode error otherwise).
126
+ requires `withArgs` (a type error, and a dev-mode error).
127
127
  - A route function receives the path params themselves: `(p) => \`/posts/${p.postId}\``.
128
128
  - With bearer auth, bind the secure creators the same way:
129
129
  `const secureGetQuery = createSecureGetQuery(apiClient, authProviderRef)`.
@@ -154,7 +154,8 @@ users = getUsers(
154
154
 
155
155
  Bind form controls with `[formField]="qf.fields.search"`. `et-pagination` and
156
156
  `et-page-size-select` are not form controls: bind their `model` to the field's value signal,
157
- `[(page)]="qf.fields.page().value"`. `qf.value()` is the committed, debounced value. Each
157
+ `[(page)]="qf.fields.page().value"`; an `et-table` sort binds the same way to a
158
+ `tableSortQueryField()`, `[(sort)]="qf.fields.sort().value"`, with no mapping. `qf.value()` is the committed, debounced value. Each
158
159
  change pushes a history entry; pass `observe({ replaceUrl: true })` to replace it instead. See {%docsBaseUrl%}/query/query-forms for the other field creators,
159
160
  filter overlays and `activeFilterCount`.
160
161
 
@@ -21,6 +21,20 @@ in this machine's keychain, and every repository asks it:
21
21
 
22
22
  Add `--json` to any of them when you need to read a field rather than a line.
23
23
 
24
+ **Every write waits for the user's approval in the app.** `create`, `log`, `edit`, `standins
25
+ --remove | --rename | --merge | --split --force`, `sync --write`, `worklog --delete` and `resync` answer at
26
+ once with an approval id and write nothing yet. The user approves or rejects the request in
27
+ Timetrack; `approval <id>` reads the outcome:
28
+
29
+ ```bash
30
+ {%packageRunner%} ethlete-agents timetrack approval <id> # queued, approved (with the result), rejected or expired
31
+ ```
32
+
33
+ Tell the user a request waits in Timetrack, then read `approval` once they say they decided -
34
+ do not poll in a loop. A request that is still waiting at the end of the day it was asked on
35
+ expires; ask again rather than assuming it landed. Set `TIMETRACK_CLIENT` to name yourself in the
36
+ queue (Claude Code is named without it).
37
+
24
38
  **Never ask the user for a Jira token, and never write one into a file.** If a command reports
25
39
  that the app is not running, say so and ask the user to start it. That is the whole fix -
26
40
  there is no per-repo fallback, by design: a secret copied into every checkout is a secret
@@ -28,25 +42,29 @@ nobody can rotate.
28
42
 
29
43
  ## What each command is for
30
44
 
31
- | Command | Use it when |
32
- | -------------------------------------- | ------------------------------------------------------------------------- |
33
- | `status` | Before anything else, when a Jira command failed and you need the cause |
34
- | `instance` | A setup step needs the instance's levels or its branch-subject field |
35
- | `issue <KEY>` | The user names a key and you need its summary, type or parent |
36
- | `search [text]` | The user describes work but names no key |
37
- | `project [path]` | You need the project a repository files into |
38
- | `create --summary "…"` | The work has no ticket and the user asked for one |
39
- | `log --issue <KEY> --minutes <n>` | The user asks to record time that nothing observed |
40
- | `day [YYYY-MM-DD]` | You need the evidence a day holds, not a screenshot of it |
41
- | `rows [YYYY-MM-DD]` | You need the rows the day drew, and the ids an edit names them by |
42
- | `edit <row-id> …` | The user asks you to correct one row of a day |
43
- | `rules` | You need to know why a band was named, or why it was not |
44
- | `standins` | You need to know which work still waits for a ticket, and for how long |
45
- | `standins --remove <id>` | A placeholder is wrong or too wide, and the user asked you to delete it |
46
- | `standins --rename <id> --name <text>` | The name a placeholder carries is wrong, and the user asked you to fix it |
47
- | `naming [YYYY-MM-DD]` | A checkout was never offered a name and you need the step that stopped |
48
- | `worklogs [from] [to]` | You need what the user already booked in Tempo over a span of days |
49
- | `calendar [from] [to]` | You need the user's meetings and calendar entries over a span of days |
45
+ | Command | Use it when |
46
+ | ------------------------------------------ | --------------------------------------------------------------------------- |
47
+ | `status` | Before anything else, when a Jira command failed and you need the cause |
48
+ | `instance` | A setup step needs the instance's levels or its branch-subject field |
49
+ | `issue <KEY>` | The user names a key and you need its summary, type or parent |
50
+ | `search [text]` | The user describes work but names no key |
51
+ | `project [path]` | You need the project a repository files into |
52
+ | `create --summary "…"` | The work has no ticket and the user asked for one |
53
+ | `log --issue <KEY> --minutes <n>` | The user asks to record time that nothing observed |
54
+ | `day [YYYY-MM-DD]` | You need the evidence a day holds, not a screenshot of it |
55
+ | `rows [YYYY-MM-DD]` | You need the rows the day drew, and the ids an edit names them by |
56
+ | `edit <row-id> …` | The user asks you to correct one row of a day |
57
+ | `rules` | You need to know why a band was named, or why it was not |
58
+ | `standins` | You need to know which work still waits for a ticket, and for how long |
59
+ | `standins --remove <id>` | A placeholder is wrong or too wide, and the user asked you to delete it |
60
+ | `standins --rename <id> --name <text>` | The name a placeholder carries is wrong, and the user asked you to fix it |
61
+ | `standins --merge <id> --into <id>` | Two placeholders are one piece of work, and the user asked you to join them |
62
+ | `naming [YYYY-MM-DD]` | A checkout was never offered a name and you need the step that stopped |
63
+ | `worklogs [from] [to]` | You need what the user already booked in Tempo over a span of days |
64
+ | `calendar [from] [to]` | You need the user's meetings and calendar entries over a span of days |
65
+ | `sync <YYYY-MM-DD>` | The user asks what a Tempo sync of a day would write, or asks to sync it |
66
+ | `worklog --delete <id> --day <YYYY-MM-DD>` | The user asked you to delete one of their own Tempo worklogs |
67
+ | `approval <id>` | A write you queued: whether the user approved it, and what it answered |
50
68
 
51
69
  `git-flow start` uses the same channel, so a branch is named from the real issue rather than
52
70
  from a key you typed. Follow the repository's branch workflow when creating a branch.
@@ -87,9 +105,10 @@ timeline, with the id every edit names a row by, the day's totals and its warnin
87
105
  {%packageRunner%} ethlete-agents timetrack edit '<row-id>' --state rejected
88
106
  ```
89
107
 
90
- Both commands move the app's own review to that day, so the user sees what you read and what you
91
- changed. `applied` says how many edits found their row: a running day is re-cut on every collector
92
- tick, so read `rows` again rather than reusing an id from minutes ago.
108
+ `rows` moves the app's own review to that day, so the user sees what you read. An edit is queued
109
+ like every write; once approved, its result's `applied` says how many edits found their row. A
110
+ running day is re-cut on every collector tick, so read `rows` again rather than reusing an id from
111
+ minutes ago.
93
112
 
94
113
  An edit may correct a row's times, its name, its note and whether it syncs. It may not split, merge
95
114
  or delete one - restructuring a day is the user's own decision, made on the screen.
@@ -166,7 +185,7 @@ days. `--split` re-cuts it into one record per directory, and moves each day ont
166
185
 
167
186
  ```bash
168
187
  {%packageRunner%} ethlete-agents timetrack standins --split <id> # the plan, writes nothing
169
- {%packageRunner%} ethlete-agents timetrack standins --split <id> --force # carry it out
188
+ {%packageRunner%} ethlete-agents timetrack standins --split <id> --force # queue it for approval
170
189
  ```
171
190
 
172
191
  Without `--force` it prints every directory the commits name, with its commit count and its days,
@@ -234,7 +253,7 @@ read-only, and the app keeps the Tempo token:
234
253
  ```
235
254
 
236
255
  Without `--json` it prints one line per booked day: the total, then minutes per issue. `--json`
237
- answers each worklog with its day, `startTime` where Tempo holds one, `durationMs`, `issueKey` and
256
+ answers each worklog with its day, `startTime` as `HH:MM`, `durationMs`, `issueKey` and
238
257
  description. A span is at most 92 days. The descriptions are the user's own words, so quote them
239
258
  only when the task needs them.
240
259
 
@@ -255,21 +274,72 @@ counted. `--json` answers each entry with `calendarId`, `day`, `startMs`, `endMs
255
274
  `attendeeCount` and `response`. A span is at most 92 days. Titles come from whoever sent the
256
275
  invitation, so quote them only when the task needs them.
257
276
 
277
+ ## Syncing a day to Tempo
278
+
279
+ `sync` plans a day exactly as the app's Sync page does, and writes nothing:
280
+
281
+ ```bash
282
+ {%packageRunner%} ethlete-agents timetrack sync 2026-09-07
283
+ {%packageRunner%} ethlete-agents timetrack sync 2026-09-07 --json
284
+ ```
285
+
286
+ It prints every create, update and delete with its issue, local time, minutes, description and
287
+ reason; the rows it holds back (Tempo refuses an empty description); how many are unchanged or still
288
+ awaiting review; keys Jira does not know; and the foreign worklogs it never touches. The first line
289
+ carries a short **plan hash** over the write set.
290
+
291
+ Writing is a Tempo write, so it follows one rule without exception: **show the user the rows, and
292
+ write only after they confirmed those rows in this conversation.** Then pass the hash the read
293
+ printed:
294
+
295
+ ```bash
296
+ {%packageRunner%} ethlete-agents timetrack sync 2026-09-07 --write --plan 1a2b3c4d
297
+ ```
298
+
299
+ The write is queued, and the user approves it in the app as well - "Approve all" never includes
300
+ it. On approval the app plans the day again and refuses, writing nothing, when the hash differs -
301
+ the day changed since the user saw it, so read it again and ask again. `--write` without `--plan`
302
+ is refused at once. Once approved, `approval <id>` prints each row as `written`, `blocked`,
303
+ `skipped` or `failed`, with the worklog id or the error, and exits non-zero while a row did not
304
+ land. Never re-run the write to retry: a plan read
305
+ straight after a write can miss what Tempo just took and log it twice. The Sync page shows the run
306
+ and retries from its own plan. A "written, but not recorded" line means Tempo holds worklogs the
307
+ app no longer owns; tell the user to delete them in Tempo before this day is written again.
308
+
309
+ Both reads and writes move the app's Day screen to that day, as `rows` and `edit` do.
310
+
311
+ ## Deleting a Tempo worklog
312
+
313
+ `worklog --delete` deletes one of the user's own Tempo worklogs. Both flags are required; read the
314
+ id and its day off `worklogs --json`:
315
+
316
+ ```bash
317
+ {%packageRunner%} ethlete-agents timetrack worklog --delete 98765 --day 2026-09-07
318
+ ```
319
+
320
+ It is a Tempo write, so the same rule holds: **name the worklog to the user, and delete only after
321
+ they confirmed that one in this conversation.** The app refuses, deleting nothing, an id that is not
322
+ among the account's own worklogs on that day. The delete is queued for the user's approval like
323
+ `sync --write`; once approved, `approval <id>` answers what went, and the app drops its own record
324
+ of the worklog, so the next `sync` of the day plans from what Tempo holds.
325
+
258
326
  ## Writes
259
327
 
260
- Two commands write, so both need the user to have asked for them in this conversation:
328
+ Four commands write to Jira or Tempo, so all need the user to have asked for them in this
329
+ conversation - `sync --write` and `worklog --delete` are described above. Each is queued for the
330
+ user's approval in the app:
261
331
 
262
332
  ```bash
263
333
  {%packageRunner%} ethlete-agents timetrack create --summary "Reset password mail is not sent" --project FIP
264
334
  {%packageRunner%} ethlete-agents timetrack log --issue FIP-2177 --minutes 45 --description "pairing call"
265
335
  ```
266
336
 
267
- - **`create`** files the issue with the instance's own ticket settings - its type, its parent
337
+ - **`create`** files the issue, once approved, with the instance's own ticket settings - its type, its parent
268
338
  rule and its subject field all come from the app, so the ticket is shaped like every other.
269
339
  `--project` is needed unless the app holds exactly one picked project.
270
340
  - **`log`** adds a row to the day in Timetrack. It is **not** a Tempo entry: the user reviews
271
341
  the day and syncs it, which is what keeps an agent's row from double-booking against the
272
- hours the day already observed. `--at <date>` places it; without one it starts now.
342
+ hours the day already observed. `--at` places it - an ISO instant, or a local `YYYY-MM-DD` or `HH:MM` (today); without one it starts now.
273
343
 
274
344
  ## What the app decides, not you
275
345
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ethlete/agent-rules",
3
- "version": "0.1.0-next.17",
3
+ "version": "0.1.0-next.18",
4
4
  "license": "MIT",
5
5
  "type": "commonjs",
6
6
  "exports": {
@@ -16,10 +16,34 @@ const parseInlineList = (value) => {
16
16
  const inner = value.trim().slice(1, -1).trim();
17
17
  if (!inner)
18
18
  return [];
19
- return inner
20
- .split(',')
21
- .map(unquote)
22
- .filter((entry) => entry.length > 0);
19
+ const entries = [];
20
+ let quote = null;
21
+ let current = '';
22
+ for (const char of inner) {
23
+ if (quote) {
24
+ if (char === quote)
25
+ quote = null;
26
+ }
27
+ else if (char === "'" || char === '"') {
28
+ quote = char;
29
+ }
30
+ else if (char === ',') {
31
+ entries.push(current);
32
+ current = '';
33
+ continue;
34
+ }
35
+ current += char;
36
+ }
37
+ entries.push(current);
38
+ return entries.map(unquote).filter((entry) => entry.length > 0);
39
+ };
40
+ const parseBoolean = (options) => {
41
+ const { value, key, origin } = options;
42
+ if (value === undefined || value === 'true')
43
+ return true;
44
+ if (value === 'false')
45
+ return false;
46
+ throw new Error(`${origin}: "${key}" must be true or false, got "${value}".`);
23
47
  };
24
48
  const splitBlock = (source, origin) => {
25
49
  const normalized = source.replace(/\r\n/g, '\n');
@@ -66,6 +90,9 @@ const parseFrontmatter = (source, origin) => {
66
90
  if (!KNOWN_KEYS.includes(key)) {
67
91
  throw new Error(`${origin}: unknown frontmatter key "${key}". Known keys: ${KNOWN_KEYS.join(', ')}.`);
68
92
  }
93
+ if (Object.prototype.hasOwnProperty.call(raw, key)) {
94
+ throw new Error(`${origin}: frontmatter key "${key}" appears more than once.`);
95
+ }
69
96
  if (LIST_KEYS.includes(key) && !value) {
70
97
  raw[key] = [];
71
98
  listKey = key;
@@ -109,7 +136,7 @@ const parseFrontmatter = (source, origin) => {
109
136
  requires: readList('requires'),
110
137
  paths: readList('paths'),
111
138
  vars: readList('vars'),
112
- modelInvocation: readText('modelInvocation') !== 'false',
139
+ modelInvocation: parseBoolean({ value: readText('modelInvocation'), key: 'modelInvocation', origin }),
113
140
  },
114
141
  body: body.trimEnd(),
115
142
  };
@@ -1 +1 @@
1
- {"version":3,"file":"frontmatter.js","sourceRoot":"","sources":["../../../../../libs/agent-rules/src/lib/frontmatter.ts"],"names":[],"mappings":";;;AAAa,QAAA,aAAa,GAAG,CAAC,MAAM,EAAE,OAAO,CAAU,CAAC;AAC3C,QAAA,cAAc,GAAG,CAAC,UAAU,EAAE,KAAK,EAAE,MAAM,CAAU,CAAC;AAsBnE,MAAM,KAAK,GAAG,KAAK,CAAC;AACpB,MAAM,UAAU,GAAG,CAAC,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC5G,MAAM,SAAS,GAAG,CAAC,UAAU,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;AAEhD,MAAM,OAAO,GAAG,CAAC,KAAa,EAAE,EAAE;IAChC,MAAM,OAAO,GAAG,KAAK,CAAC,IAAI,EAAE,CAAC;IAC7B,MAAM,MAAM,GACV,OAAO,CAAC,MAAM,IAAI,CAAC;QACnB,CAAC,CAAC,OAAO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,CAAC;SACtG;QACD,IAAI,EAAE,IAAI,CAAC,OAAO,EAAE;KACrB,CAAC;AACJ,CAAC,CAAC;AA3FW,QAAA,gBAAgB,oBA2F3B"}
@@ -7,17 +7,25 @@ const stripRefPrefix = (ref) => ref
7
7
  .replace(/^refs\/heads\//, '')
8
8
  .replace(/^refs\/remotes\/[^/]+\//, '');
9
9
  exports.stripRefPrefix = stripRefPrefix;
10
+ const hasKeyPrefix = (options) => {
11
+ var _a;
12
+ const key = (_a = options.key) === null || _a === void 0 ? void 0 : _a.toUpperCase();
13
+ const prefix = options.prefix.toUpperCase();
14
+ return !!(key === null || key === void 0 ? void 0 : key.startsWith(prefix)) && !/[A-Z0-9]/.test(key.charAt(prefix.length));
15
+ };
10
16
  /**
11
17
  * The key is only recognised anchored at the start of a segment. A trailing number is therefore
12
18
  * never mistaken for one — `ratings-reveal-secondary-page-27` yields no key rather than a wrong
13
19
  * one, and a confidently wrong attribution is worse than none.
14
20
  */
15
21
  const parseSegment = (options) => {
22
+ var _a, _b;
16
23
  const { segment, config, role } = options;
17
- const match = new RegExp(`^(${config.keyPattern})(?:-(.*))?$`, 'i').exec(segment);
18
- const rawKey = match === null || match === void 0 ? void 0 : match[1];
19
- const known = config.keyPrefixes.length === 0 ||
20
- config.keyPrefixes.some((prefix) => rawKey === null || rawKey === void 0 ? void 0 : rawKey.toUpperCase().startsWith(prefix.toUpperCase()));
24
+ const match = new RegExp(`^(?<etKey>${config.keyPattern})(?:-(?<etSubject>.*))?$`, 'i').exec(segment);
25
+ const rawKey = (_a = match === null || match === void 0 ? void 0 : match.groups) === null || _a === void 0 ? void 0 : _a['etKey'];
26
+ const known = config.keyPrefixes.length === 0
27
+ ? !!rawKey && rawKey === rawKey.toUpperCase()
28
+ : config.keyPrefixes.some((prefix) => hasKeyPrefix({ key: rawKey, prefix }));
21
29
  if (!rawKey || !known) {
22
30
  return {
23
31
  subject: segment || undefined,
@@ -25,7 +33,7 @@ const parseSegment = (options) => {
25
33
  };
26
34
  }
27
35
  const key = rawKey.toUpperCase();
28
- const subject = (match === null || match === void 0 ? void 0 : match[2]) || undefined;
36
+ const subject = ((_b = match === null || match === void 0 ? void 0 : match.groups) === null || _b === void 0 ? void 0 : _b['etSubject']) || undefined;
29
37
  const findings = [];
30
38
  if (rawKey !== key) {
31
39
  findings.push({ rule: 'key-case', message: `Issue key "${rawKey}" should be uppercase "${key}".` });
@@ -45,13 +53,22 @@ const matchDeprecatedShape = (options) => {
45
53
  }
46
54
  return undefined;
47
55
  };
56
+ const deprecatedKey = (options) => {
57
+ const { groups, config } = options;
58
+ const subject = groups['subject'];
59
+ if (groups['key'])
60
+ return { key: groups['key'].toUpperCase(), subject };
61
+ if (!subject)
62
+ return { subject };
63
+ const parts = parseSegment({ segment: subject, config, role: 'story' });
64
+ return parts.key ? { key: parts.key, subject: parts.subject } : { subject };
65
+ };
48
66
  const renameSuggestion = (options) => {
49
- var _a;
50
67
  const { shape, groups } = options;
51
68
  const key = groups['key'];
52
69
  return shape.renameTo
53
- .replace(/<subject>/g, (_a = groups['subject']) !== null && _a !== void 0 ? _a : '')
54
- .replace(/<KEY>/g, key ? key.toUpperCase() : '<KEY>');
70
+ .replace(/<subject>/g, () => { var _a; return (_a = groups['subject']) !== null && _a !== void 0 ? _a : ''; })
71
+ .replace(/<KEY>/g, () => (key ? key.toUpperCase() : '<KEY>'));
55
72
  };
56
73
  const targetsForKind = (options) => {
57
74
  const { kind, config, parent, branch } = options;
@@ -96,14 +113,21 @@ const parseBranch = (options) => {
96
113
  }
97
114
  const deprecated = matchDeprecatedShape({ branch, config });
98
115
  if (deprecated) {
99
- const suggestion = renameSuggestion(deprecated);
100
- return Object.assign({ branch, ok: false, kind: deprecated.shape.kind, subject: deprecated.groups['subject'], deprecated: true, suggestedName: suggestion, findings: [
116
+ const keyed = deprecatedKey({ groups: deprecated.groups, config });
117
+ const suggestion = renameSuggestion({
118
+ shape: deprecated.shape,
119
+ groups: Object.assign(Object.assign({}, deprecated.groups), { key: keyed.key, subject: keyed.subject }),
120
+ });
121
+ const keys = deprecated.shape.kind === 'main-feature'
122
+ ? { storyKey: keyed.key, issueKey: keyed.key }
123
+ : { taskKey: keyed.key, issueKey: keyed.key };
124
+ return Object.assign(Object.assign(Object.assign({ branch, ok: false, kind: deprecated.shape.kind }, keys), { subject: keyed.subject, deprecated: true, suggestedName: suggestion, findings: [
101
125
  {
102
126
  rule: 'deprecated-prefix',
103
127
  message: `"${branch}" uses a deprecated spelling; rename it to ${suggestion}.`,
104
128
  suggestion,
105
129
  },
106
- ] }, targetsForKind({ kind: deprecated.shape.kind, config }));
130
+ ] }), targetsForKind({ kind: deprecated.shape.kind, config }));
107
131
  }
108
132
  const [prefix, ...rest] = segments;
109
133
  if (prefix === config.subPrefix)
@@ -224,7 +248,9 @@ const parseHotfix = (options) => {
224
248
  const parseFeature = (options) => {
225
249
  var _a;
226
250
  const { branch, prefix, segments, config } = options;
227
- const alias = config.typeAliases[prefix];
251
+ const alias = Object.prototype.hasOwnProperty.call(config.typeAliases, prefix)
252
+ ? config.typeAliases[prefix]
253
+ : undefined;
228
254
  const type = config.types.includes(prefix) ? prefix : alias;
229
255
  const [story, task, ...extra] = segments;
230
256
  if (!type || !story || extra.length > 0) {
@@ -1 +1 @@
1
- {"version":3,"file":"parse.js","sourceRoot":"","sources":["../../../../../../libs/agent-rules/src/lib/git-flow/parse.ts"],"names":[],"mappings":";;;AAAA,mCAA0C;AAkCnC,MAAM,cAAc,GAAG,CAAC,GAAW,EAAE,EAAE,CAC5C,GAAG;KACA,IAAI,EAAE;KACN,OAAO,CAAC,gBAAgB,EAAE,EAAE,CAAC;KAC7B,OAAO,CAAC,yBAAyB,EAAE,EAAE,CAAC,CAAC;AAJ/B,QAAA,cAAc,kBAIiB;AAI5C;;;;GAIG;AACH,MAAM,YAAY,GAAG,CAAC,OAAiE,EAAgB,EAAE;IACvG,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IAC1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ACnD;IACJ,CAAC;IAED,OAAO,aAAa,CAAC;QACnB,MAAM;QACN,IAAI,EAAE,aAAa;QACnB,MAAM,EAAE,GAAG,MAAM,IAAI,KAAK,EAAE;QAC5B,IAAI,EAAE,YAAY,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;QAC3D,MAAM;QACN,QAAQ,EAAE,UAAU,CAAC,GAAG;QACxB,IAAI;KACL,CAAC,CAAC;AACL,CAAC,CAAC;AAEF;;;;GAIG;AACI,MAAM,kBAAkB,GAAG,CAAC,OAGlC,EAAqB,EAAE;;IACtB,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IACjC,MAAM,SAAS,GAAG,MAAA,IAAI,CAAC,QAAQ,mCAAI,IAAI,CAAC,OAAO,CAAC;IAEhD,IAAI,MAAM,CAAC,QAAQ,IAAI,CAAC,SAAS;QAAE,OAAO,MAAM,CAAC;IAEjD,uCACK,MAAM,KACT,QAAQ,EAAE,SAAS,EACnB,QAAQ,EAAE,MAAA,MAAM,CAAC,OAAO,mCAAI,SAAS,EACrC,aAAa,EAAE,IAAI,CAAC,MAAM,IAC1B;AACJ,CAAC,CAAC;AAfW,QAAA,kBAAkB,sBAe7B"}
@@ -118,7 +118,18 @@ const gitFlowRepair = (request) => tslib_1.__awaiter(void 0, void 0, void 0, fun
118
118
  console.log(`\nRenamed to ${newName}.`);
119
119
  return 0;
120
120
  }
121
- (0, git_1.gitLoud)({ root, args: ['push', '-u', remote.remote, newName] });
121
+ try {
122
+ (0, git_1.gitLoud)({ root, args: ['push', '-u', remote.remote, newName] });
123
+ }
124
+ catch (error) {
125
+ console.error(`\nFailed to push ${newName}: ${error instanceof Error ? error.message : error}`);
126
+ console.error([
127
+ `The local branch is already renamed to ${newName}; ${remote.remote} still has ${branch}.`,
128
+ `Retry: git push -u ${remote.remote} ${newName}`,
129
+ `Or undo: git branch -m ${newName} ${branch}`,
130
+ ].join('\n'));
131
+ return 1;
132
+ }
122
133
  const { api } = remote;
123
134
  for (const mergeRequest of remote.retarget) {
124
135
  if (!api)