hiiro 0.1.366 → 0.1.368
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +47 -0
- data/CLAUDE.md +1 -0
- data/README.md +79 -53
- data/bin/h-alias +28 -0
- data/bin/h-bin +20 -0
- data/bin/h-env +25 -0
- data/bin/h-herdr +156 -0
- data/bin/h-task +1 -0
- data/bin/t +1 -0
- data/bin/tt +1 -0
- data/docs/h-bin.md +49 -2
- data/docs/h-herdr.md +41 -0
- data/docs/h-subtask.md +5 -44
- data/docs/h-task.md +18 -712
- data/docs/h.md +2 -2
- data/docs/t.md +89 -376
- data/docs/why-t.md +23 -25
- data/exe/h +1 -0
- data/exe/t +7 -0
- data/exe/tt +7 -0
- data/herdr-plugin/herdr-plugin.toml +47 -0
- data/lib/hiiro/current_task.rb +92 -0
- data/lib/hiiro/error.rb +5 -0
- data/lib/hiiro/git/worktrees.rb +1 -1
- data/lib/hiiro/git.rb +8 -2
- data/lib/hiiro/task_cli.rb +788 -0
- data/lib/hiiro/task_sessions.rb +1 -1
- data/lib/hiiro/tasks.rb +40 -27
- data/lib/hiiro/version.rb +1 -1
- data/lib/hiiro.rb +22 -20
- metadata +14 -2
- data/bin/t +0 -526
- data/bin/tt +0 -20
- data/lib/hiiro/task_scope.rb +0 -92
data/docs/h-task.md
CHANGED
|
@@ -8,722 +8,28 @@ Task todos use the existing `todos` table shared with `h todo`. `t` writes to th
|
|
|
8
8
|
|
|
9
9
|
## t
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
The grammar is `t TASK COMMAND...`. Bare `t` lists all tasks, including done and archived tasks. `t TASK` shows the task. Only exact root `t help` displays generic usage and native scoped help without looking up a task. First words such as `new`, `show`, `edit`, `pry`, and `he` are task references, not root commands or help abbreviations.
|
|
14
|
-
|
|
15
|
-
Named references match an exact name first, then a unique case-sensitive prefix. Ambiguous prefixes are errors. Unknown names fail except with `t NAME new` or `t NAME todo add TEXT...`. Explicit `new` creates exactly `NAME` without prefix resolution. `t TASK help` shows task commands, and `t TASK todo help` shows todo commands. Native command abbreviations apply inside these scopes.
|
|
16
|
-
|
|
17
|
-
Use `.` to select the current task, including when supplying a payload: `t . next 'Compare the export'`. Selection checks the calling Herdr workspace, then the current directory inside a task home, code directory, or registered directory, then the saved task. Workspace context wins over a conflicting directory. Ambiguous matches and invalid, stale, or conflicting Herdr IDs are errors. Outside Herdr, an unrelated focused workspace does not affect selection. An explicit name bypasses context lookup.
|
|
18
|
-
|
|
19
|
-
`t TASK current` prints the resolved name and saves a named selection without changing terminal focus. `t . current` only prints it. The fallback is a `PinRecord` with `command='t'`, `key='current_task'`, and the task ID as a JSON integer in `value_json`. A missing saved task is an error when selection reaches that fallback. Reads and workspace opens through `.` do not replace it.
|
|
20
|
-
|
|
21
|
-
### Task records
|
|
22
|
-
|
|
23
|
-
```text
|
|
24
|
-
t
|
|
25
|
-
t TASK
|
|
26
|
-
t TASK show
|
|
27
|
-
t TASK current
|
|
28
|
-
t NAME new
|
|
29
|
-
t TASK next [TEXT...] [--clear]
|
|
30
|
-
t TASK status [active|waiting|done|archived]
|
|
31
|
-
t TASK waiting [TEXT...] [--clear]
|
|
32
|
-
t TASK done
|
|
33
|
-
t TASK archive
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
Bare `t` lists tasks regardless of context or the saved task. There is no root `list`, `ls`, `new`, or `show` action. `next`, `waiting`, and `status` without a payload display the selected task's current value.
|
|
37
|
-
|
|
38
|
-
`t NAME new` creates a record and `~/notes/work/NAME`. It never creates a Git worktree, moves code, or launches Herdr. Repeating `new` keeps the exact existing record and ensures its home exists. Names contain 1-120 ASCII letters, digits, dots, underscores, or hyphens and start with a letter or digit. Existing names that contain other characters remain usable, with those characters percent-encoded in the computed home directory name.
|
|
39
|
-
|
|
40
|
-
Setting waiting text changes status to `waiting`. Clearing that text changes a waiting task back to `active`. `done` and `archive` change status and record timestamps. They never remove todos, a task home, a file, a directory, a link, or a workspace. `t TASK status active` reopens a task.
|
|
41
|
-
|
|
42
|
-
```bash
|
|
43
|
-
t audit-invoices new
|
|
44
|
-
t audit-invoices next 'Compare the September export'
|
|
45
|
-
t audit-invoices waiting 'Finance approval'
|
|
46
|
-
t audit-invoices waiting --clear
|
|
47
|
-
t audit-invoices done
|
|
48
|
-
t audit-invoices
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
### Task todos
|
|
52
|
-
|
|
53
|
-
```text
|
|
54
|
-
t TASK todo
|
|
55
|
-
t TASK todo list
|
|
56
|
-
t TASK todo ls
|
|
57
|
-
t TASK todo add TEXT...
|
|
58
|
-
t TASK todo rm ID
|
|
59
|
-
tt TASK [COMMAND...]
|
|
60
|
-
tt
|
|
61
|
-
tt help
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
`tt TASK ...` delegates to `t TASK todo ...`. Bare `tt` means `t . todo`, and `tt help` shows todo help without task lookup. The default todo action is listing. `t - todo` and `tt -` select orphan todos, with `add` and `rm` available in that scope. `-` is invalid outside todo commands and never creates a task.
|
|
65
|
-
|
|
66
|
-
If a named `todo add` finds no match, it creates the task using `new` validation and home rules, then adds one todo with status `not_started`. Task and todo database writes use one immediate SQLite transaction. Other todo actions never create tasks.
|
|
67
|
-
|
|
68
|
-
Every token after `add` is literal text, including flags and `--`, except that leading `add -h` or `add --help` displays native option help. The tokens are joined with spaces. Missing, empty, or whitespace-only text fails before task creation.
|
|
69
|
-
|
|
70
|
-
```bash
|
|
71
|
-
t audit-invoices todo add Compare the September export
|
|
72
|
-
tt audit-invoices add Inspect --help output
|
|
73
|
-
t audit-invoices todo
|
|
74
|
-
t audit-invoices todo rm 42
|
|
75
|
-
tt - add Buy printer paper
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
Use an ID printed by `show` or todo listing in place of `42`. `rm` accepts exactly one decimal database ID belonging to the selected scope, not a list position or suffix. Missing, invalid, or extra arguments fail.
|
|
79
|
-
|
|
80
|
-
Task display and todo listing print each matching item's ID, status, and text in ID order. Matching uses the full task name exactly, including legacy rows with both `task_name` and `subtask_name`. A parent task does not include its subtasks' todos. New task todos store the full task name in `task_name` and leave `subtask_name` unset. Orphan rows leave both unset.
|
|
81
|
-
|
|
82
|
-
Each task still has one independent `next_action`. Adding or removing todos does not change that field, task status, or saved selection. `t` has no todo-completion command or automatic next-action promotion. The separate `h task` and `h todo` commands keep their existing behavior.
|
|
83
|
-
|
|
84
|
-
### Directory, link, PR, and file references
|
|
85
|
-
|
|
86
|
-
```text
|
|
87
|
-
t TASK directory add PATH [--primary] [--label LABEL]
|
|
88
|
-
t TASK directory list
|
|
89
|
-
t TASK directory open [ID|PATH|LABEL]
|
|
90
|
-
t TASK link add URL [--kind general|issue|thread] [--label LABEL]
|
|
91
|
-
t TASK link list [--kind general|issue|thread]
|
|
92
|
-
t TASK link open [ID|URL|LABEL]
|
|
93
|
-
t TASK pr add URL [--label LABEL]
|
|
94
|
-
t TASK pr list
|
|
95
|
-
t TASK pr open [ID|URL|LABEL]
|
|
96
|
-
t TASK file add PATH [--label LABEL]
|
|
97
|
-
t TASK file list
|
|
98
|
-
t TASK file open [ID|PATH|LABEL]
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
Directory and file attachments must already exist. `add` stores their canonical paths without moving or copying anything. Repeating an identical attachment does not create another reference. `--primary` marks an attached directory as the default code directory for new workspace tabs and panes. An existing directory can be a Git worktree. Registering it does not create a worktree or alter sparse checkout.
|
|
102
|
-
|
|
103
|
-
Links must be absolute HTTP or HTTPS URLs. `link list` includes PR references unless a kind filter is present. PRs use the same resource storage as other links and do not require a Git repository or provider API.
|
|
104
|
-
|
|
105
|
-
`file list` also discovers files in the task home, including documents, without registration. Home files can be opened by a relative path or an unambiguous basename. An omitted open selector works only when exactly one resource matches. Otherwise, the command requires an ID, path, URL, or unique label.
|
|
106
|
-
|
|
107
|
-
`open` uses the operating system's default application. Attachments remain references even after task completion. List commands also accept `ls`. Leaf help, such as `t audit-invoices directory add --help`, lists options without running the action.
|
|
108
|
-
|
|
109
|
-
### Documents
|
|
110
|
-
|
|
111
|
-
```text
|
|
112
|
-
t TASK doc new NAME [TITLE...]
|
|
113
|
-
t TASK doc list
|
|
114
|
-
t TASK doc open [NAME]
|
|
115
|
-
```
|
|
116
|
-
|
|
117
|
-
`doc new` creates a Markdown file in the task home with an initial heading. It never overwrites an existing file. Documents have a stable task-ID prefix, such as `task-42-investigation.md`, to avoid collisions in `mdoc`'s shared HTML output directory. `t TASK doc open investigation` accepts the short name and invokes `mdoc`. Existing Markdown files in the task home also appear without registration.
|
|
118
|
-
|
|
119
|
-
Task creation, metadata, references, and document creation/listing work without Git or Herdr when a named task is supplied. Document reading requires `mdoc` on `PATH` and its existing configuration.
|
|
120
|
-
|
|
121
|
-
### Herdr workspaces, tabs, and panes
|
|
122
|
-
|
|
123
|
-
```text
|
|
124
|
-
t TASK workspace [--directory PATH]
|
|
125
|
-
t TASK switch [--directory PATH]
|
|
126
|
-
t TASK workspace --show
|
|
127
|
-
t TASK switch --show
|
|
128
|
-
t TASK tab list
|
|
129
|
-
t TASK tab new [LABEL] [--directory PATH] [--command COMMAND]
|
|
130
|
-
t TASK tab open ID|LABEL
|
|
131
|
-
t TASK pane list
|
|
132
|
-
t TASK pane open ID|LABEL
|
|
133
|
-
t TASK pane read ID|LABEL
|
|
134
|
-
t TASK pane run ID|LABEL -- COMMAND...
|
|
135
|
-
t TASK pane split ID|LABEL [--direction right|down] [--directory PATH] [--command COMMAND]
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
These commands require a running Herdr server. `t TASK workspace` and its `switch` alias focus the workspace with the task's label or create one. They save a named task only after a successful switch. `t . workspace` leaves the saved fallback unchanged. A new workspace starts in the explicit directory, the primary code directory, the legacy worktree, or the task home, in that order. `--directory` changes that operation's start directory without changing stored attachments.
|
|
139
|
-
|
|
140
|
-
`--show` queries the current tabs and panes without saving, focusing, or creating a workspace. `workspace` and `switch` are direct commands, not groups. Native Hiiro abbreviation matching accepts `t TASK wor`.
|
|
141
|
-
|
|
142
|
-
Tab and pane selectors must belong to the selected task's workspace. Duplicate labels require a live ID. No pane or tab ID is stored as durable task identity. Task workspace labels follow Herdr's dot-to-underscore normalization. Colliding task or workspace labels are errors rather than fuzzy matches.
|
|
143
|
-
|
|
144
|
-
Use `--` before literal command arguments that begin with a dash:
|
|
145
|
-
|
|
146
|
-
```bash
|
|
147
|
-
t audit-invoices pane run PANE_ID -- printf '%s\n' --example
|
|
148
|
-
```
|
|
149
|
-
|
|
150
|
-
### Native AI sessions
|
|
151
|
-
|
|
152
|
-
`t TASK omp`, `t TASK codex` or `cdx`, and `t TASK claude` or `cld` create new focused tabs in the task workspace. They launch the native `omp`, `codex`, and `claude` executables, respectively. The workspace is created if needed. Fresh sessions are the default.
|
|
153
|
-
|
|
154
|
-
Only the first tool argument can select resume mode. A nonempty prefix of `resume`, such as `r`, `res`, or `resume`, consumes that token. OMP and Claude receive `--resume`; Codex receives its `resume` subcommand.
|
|
155
|
-
|
|
156
|
-
With no remaining arguments, resume focuses the unique genuinely running tool in that workspace, using Herdr's agent metadata rather than the tab label. Multiple running matches are an error that reports their IDs. If none is running, a new tab launches the native resume picker.
|
|
157
|
-
|
|
158
|
-
With any remaining arguments, resume always opens a new tab and forwards those arguments unchanged. Session IDs and options belong to the native CLI. Other arguments, including `--help` and `--`, also pass through unchanged. `t` does not inject model, permission, continue, or fresh-session flags.
|
|
159
|
-
|
|
160
|
-
```bash
|
|
161
|
-
t audit-invoices omp
|
|
162
|
-
t audit-invoices cdx r
|
|
163
|
-
t audit-invoices cld resume SESSION_ID
|
|
164
|
-
t audit-invoices codex resume --help
|
|
165
|
-
t audit-invoices claude --help
|
|
166
|
-
```
|
|
167
|
-
|
|
168
|
-
The launcher scopes live-pane lookup to the task workspace. Persisted session discovery remains native CLI behavior and is not necessarily task-isolated when tasks share a directory. `t` performs no auth or API requests and makes no automatic Git changes.
|
|
11
|
+
`h task` is a symlink to `t`, so `h task ARGS...` is `t ARGS...`. The grammar is `t COMMAND [TASK] [ARGS...]`: the command comes first, and commands that act on a task take it from the first positional argument when that word names a task (exact or unique prefix); otherwise the current task is used and the word stays in the payload. `-t TASK` forces a task, `-f` picks one with a fuzzy finder, `.` is the current task, and `-` selects orphan todos. See [t](t.md) for every command.
|
|
169
12
|
|
|
170
13
|
## h task
|
|
171
14
|
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
## Synopsis
|
|
175
|
-
|
|
176
|
-
```bash
|
|
177
|
-
h task <subcommand> [args]
|
|
178
|
-
```
|
|
179
|
-
|
|
180
|
-
## Subcommands
|
|
181
|
-
|
|
182
|
-
### app
|
|
183
|
-
|
|
184
|
-
Open a named app in a new Herdr tab within the current task workspace. With no argument, opens a fuzzyfind selector over configured apps.
|
|
185
|
-
|
|
186
|
-
**Examples**
|
|
187
|
-
|
|
188
|
-
```bash
|
|
189
|
-
h task app
|
|
190
|
-
h task app api
|
|
191
|
-
```
|
|
192
|
-
|
|
193
|
-
---
|
|
194
|
-
|
|
195
|
-
### apps
|
|
196
|
-
|
|
197
|
-
List all configured apps and their relative paths.
|
|
198
|
-
|
|
199
|
-
**Examples**
|
|
200
|
-
|
|
201
|
-
```bash
|
|
202
|
-
h task apps
|
|
203
|
-
```
|
|
204
|
-
|
|
205
|
-
---
|
|
206
|
-
|
|
207
|
-
### branch
|
|
208
|
-
|
|
209
|
-
Print the git branch for a task. With no argument, opens a fuzzyfind selector. Outputs nothing if the tree is detached.
|
|
210
|
-
|
|
211
|
-
**Options**
|
|
212
|
-
|
|
213
|
-
| Flag | Short | Description | Default |
|
|
214
|
-
|------|-------|-------------|---------|
|
|
215
|
-
| `--task` | `-t` | Task name | current task |
|
|
216
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
217
|
-
| `--all` | `-a` | Print branch for every task; positional args become prefix filters (OR'd) | false |
|
|
218
|
-
|
|
219
|
-
**Examples**
|
|
220
|
-
|
|
221
|
-
```bash
|
|
222
|
-
h task branch
|
|
223
|
-
h task branch my-feature
|
|
224
|
-
h task branch -a # print branch for every task
|
|
225
|
-
h task branch -a feat bug # tasks whose name starts with "feat" or "bug"
|
|
226
|
-
```
|
|
227
|
-
|
|
228
|
-
---
|
|
229
|
-
|
|
230
|
-
### branches
|
|
231
|
-
|
|
232
|
-
List branches for the current task. Delegates to `h branch`.
|
|
233
|
-
|
|
234
|
-
---
|
|
235
|
-
|
|
236
|
-
### cbranch
|
|
237
|
-
|
|
238
|
-
Print the git branch of the **current** task. Exits with an error if not in a task.
|
|
239
|
-
|
|
240
|
-
**Examples**
|
|
241
|
-
|
|
242
|
-
```bash
|
|
243
|
-
h task cbranch
|
|
244
|
-
```
|
|
245
|
-
|
|
246
|
-
---
|
|
247
|
-
|
|
248
|
-
### cd
|
|
249
|
-
|
|
250
|
-
Send a `cd` command to the current Herdr pane, navigating to a task's worktree or app subdirectory.
|
|
251
|
-
|
|
252
|
-
**Options**
|
|
253
|
-
|
|
254
|
-
| Flag | Short | Description | Default |
|
|
255
|
-
|------|-------|-------------|---------|
|
|
256
|
-
| `--task` | `-t` | Task name | current task |
|
|
257
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
258
|
-
|
|
259
|
-
**Examples**
|
|
260
|
-
|
|
261
|
-
```bash
|
|
262
|
-
h task cd
|
|
263
|
-
h task cd my-feature
|
|
264
|
-
h task cd my-feature api
|
|
265
|
-
h task cd -t my-feature
|
|
266
|
-
```
|
|
267
|
-
|
|
268
|
-
---
|
|
269
|
-
|
|
270
|
-
### csession
|
|
271
|
-
|
|
272
|
-
Print the Herdr workspace label stored for the **current** task.
|
|
273
|
-
|
|
274
|
-
**Examples**
|
|
275
|
-
|
|
276
|
-
```bash
|
|
277
|
-
h task csession
|
|
278
|
-
```
|
|
279
|
-
|
|
280
|
-
---
|
|
281
|
-
|
|
282
|
-
### ctree
|
|
283
|
-
|
|
284
|
-
Print the worktree name of the **current** task.
|
|
285
|
-
|
|
286
|
-
**Examples**
|
|
287
|
-
|
|
288
|
-
```bash
|
|
289
|
-
h task ctree
|
|
290
|
-
```
|
|
291
|
-
|
|
292
|
-
---
|
|
293
|
-
|
|
294
|
-
### current
|
|
295
|
-
|
|
296
|
-
Print the name of the current task based on the Herdr workspace or worktree match. Exits with an error if not in a task.
|
|
297
|
-
|
|
298
|
-
**Examples**
|
|
299
|
-
|
|
300
|
-
```bash
|
|
301
|
-
h task current
|
|
302
|
-
```
|
|
303
|
-
|
|
304
|
-
---
|
|
305
|
-
|
|
306
|
-
### edit
|
|
307
|
-
|
|
308
|
-
Open the `tasks.rb` source file in your editor.
|
|
309
|
-
### file
|
|
310
|
-
|
|
311
|
-
Manage tracked app files for the current task. Delegates to the app files system.
|
|
312
|
-
|
|
313
|
-
**Examples**
|
|
314
|
-
|
|
315
|
-
```bash
|
|
316
|
-
h task file ls
|
|
317
|
-
h task file add myapp path/to/file.rb
|
|
318
|
-
```
|
|
319
|
-
|
|
320
|
-
---
|
|
321
|
-
|
|
322
|
-
### from
|
|
323
|
-
|
|
324
|
-
Register an existing git worktree as a Hiiro task and switch to it. The path is normalized to the worktree root with `git rev-parse --show-toplevel`, then stored as the task's tree path.
|
|
325
|
-
|
|
326
|
-
**Examples**
|
|
327
|
-
|
|
328
|
-
```bash
|
|
329
|
-
h task from ~/ic_repos/other_repo_base_dir other-task
|
|
330
|
-
h task path other-task
|
|
331
|
-
h task switch other-task
|
|
332
|
-
```
|
|
333
|
-
|
|
334
|
-
Stored task shape:
|
|
335
|
-
|
|
336
|
-
```js
|
|
337
|
-
{
|
|
338
|
-
name: "other-task",
|
|
339
|
-
tree: "/Users/josh/ic_repos/other_repo_base_dir",
|
|
340
|
-
session: "other-task"
|
|
341
|
-
}
|
|
342
|
-
```
|
|
343
|
-
|
|
344
|
-
---
|
|
345
|
-
|
|
346
|
-
### ls / list
|
|
347
|
-
|
|
348
|
-
List all tasks with their worktree, branch, and workspace label. It also shows available worktrees and extra Herdr workspaces.
|
|
349
|
-
|
|
350
|
-
A `*` prefix marks the current task. An `@` prefix indicates the Herdr workspace is focused.
|
|
351
|
-
|
|
352
|
-
**Options**
|
|
353
|
-
|
|
354
|
-
| Flag | Short | Description | Default |
|
|
355
|
-
|------|-------|-------------|---------|
|
|
356
|
-
| `--tag` | `-t` | Filter by tag (OR logic; repeatable) | all |
|
|
357
|
-
|
|
358
|
-
**Examples**
|
|
359
|
-
|
|
360
|
-
```bash
|
|
361
|
-
h task ls
|
|
362
|
-
h task ls -t urgent
|
|
363
|
-
h task ls -t api -t frontend
|
|
364
|
-
```
|
|
365
|
-
|
|
366
|
-
---
|
|
367
|
-
|
|
368
|
-
### path
|
|
369
|
-
|
|
370
|
-
Print the absolute path to a task's worktree or app subdirectory. With glob patterns, lists matching files.
|
|
371
|
-
|
|
372
|
-
**Options**
|
|
373
|
-
|
|
374
|
-
| Flag | Short | Description | Default |
|
|
375
|
-
|------|-------|-------------|---------|
|
|
376
|
-
| `--task` | `-t` | Task name | current task |
|
|
377
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
378
|
-
| `--all` | `-a` | Print path for every task; positional args become prefix filters (OR'd). App / glob args are ignored in this mode. | false |
|
|
379
|
-
|
|
380
|
-
**Examples**
|
|
381
|
-
|
|
382
|
-
```bash
|
|
383
|
-
h task path
|
|
384
|
-
h task path my-feature
|
|
385
|
-
h task path my-feature api
|
|
386
|
-
h task path my-feature api "**/*.rb"
|
|
387
|
-
h task path -a # print worktree path for every task
|
|
388
|
-
h task path -a feat bug # tasks whose name starts with "feat" or "bug"
|
|
389
|
-
```
|
|
390
|
-
|
|
391
|
-
---
|
|
392
|
-
|
|
393
|
-
### prune
|
|
394
|
-
|
|
395
|
-
Detach worktree associations whose directories are missing. The task record, metadata, and resource references remain. Tasks without worktrees are not pruned. Defaults to a dry-run.
|
|
396
|
-
|
|
397
|
-
**Options**
|
|
398
|
-
|
|
399
|
-
| Flag | Short | Description | Default |
|
|
400
|
-
|------|-------|-------------|---------|
|
|
401
|
-
| `--force` | `-f` | Detach missing worktrees | false |
|
|
402
|
-
|
|
403
|
-
**Examples**
|
|
404
|
-
|
|
405
|
-
```bash
|
|
406
|
-
h task prune # show what would be pruned
|
|
407
|
-
h task prune -f # detach missing worktrees, retaining task records
|
|
408
|
-
```
|
|
409
|
-
|
|
410
|
-
---
|
|
411
|
-
|
|
412
|
-
### prs
|
|
413
|
-
|
|
414
|
-
List PRs for the current task. Delegates to `h pr`.
|
|
415
|
-
|
|
416
|
-
---
|
|
417
|
-
|
|
418
|
-
### queue
|
|
419
|
-
|
|
420
|
-
Run the Claude prompt queue scoped to the current task. All `h queue` subcommands are available. See [h-queue](h-queue.md).
|
|
421
|
-
|
|
422
|
-
**Examples**
|
|
423
|
-
|
|
424
|
-
```bash
|
|
425
|
-
h task queue ls
|
|
426
|
-
h task queue add "Fix the login bug"
|
|
427
|
-
h task queue hadd
|
|
428
|
-
```
|
|
429
|
-
|
|
430
|
-
---
|
|
431
|
-
|
|
432
|
-
### resume
|
|
433
|
-
|
|
434
|
-
Associate an available worktree with a new task or an existing task whose worktree was detached, then switch to it. Existing task metadata is preserved. With no argument, opens a fuzzyfind selector over available worktrees.
|
|
435
|
-
|
|
436
|
-
**Examples**
|
|
437
|
-
|
|
438
|
-
```bash
|
|
439
|
-
h task resume
|
|
440
|
-
h task resume my-feature/main
|
|
441
|
-
```
|
|
442
|
-
|
|
443
|
-
---
|
|
444
|
-
|
|
445
|
-
### run
|
|
446
|
-
|
|
447
|
-
Run linters, tests, or formatters against changed files for the current task. Delegates to the runner tool system.
|
|
448
|
-
|
|
449
|
-
**Examples**
|
|
450
|
-
|
|
451
|
-
```bash
|
|
452
|
-
h task run
|
|
453
|
-
h task run lint
|
|
454
|
-
h task run test ruby
|
|
455
|
-
```
|
|
456
|
-
|
|
457
|
-
---
|
|
458
|
-
|
|
459
|
-
### save
|
|
460
|
-
|
|
461
|
-
Read and report the current task's Herdr tab state.
|
|
462
|
-
|
|
463
|
-
**Examples**
|
|
464
|
-
|
|
465
|
-
```bash
|
|
466
|
-
h task save
|
|
467
|
-
```
|
|
468
|
-
|
|
469
|
-
---
|
|
470
|
-
|
|
471
|
-
### service
|
|
472
|
-
|
|
473
|
-
Manage dev services scoped to the current task. All `h service` subcommands are available. See [h-service](h-service.md).
|
|
474
|
-
|
|
475
|
-
**Examples**
|
|
476
|
-
|
|
477
|
-
```bash
|
|
478
|
-
h task service ls
|
|
479
|
-
h task service start my-rails
|
|
480
|
-
```
|
|
481
|
-
|
|
482
|
-
---
|
|
483
|
-
|
|
484
|
-
### name
|
|
485
|
-
|
|
486
|
-
Print the full task name. With no argument, opens a fuzzyfind selector. Useful for scripting alongside `tree -a`, `branch -a`, and `path -a` (results are sorted by name across all four, so they line up).
|
|
487
|
-
|
|
488
|
-
**Options**
|
|
489
|
-
|
|
490
|
-
| Flag | Short | Description | Default |
|
|
491
|
-
|------|-------|-------------|---------|
|
|
492
|
-
| `--task` | `-t` | Task name | current task |
|
|
493
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
494
|
-
| `--all` | `-a` | Print every task's name; positional args become prefix filters (OR'd) | false |
|
|
495
|
-
|
|
496
|
-
**Examples**
|
|
497
|
-
|
|
498
|
-
```bash
|
|
499
|
-
h task name -a # list every task name
|
|
500
|
-
h task name -a feat # only tasks starting with "feat"
|
|
501
|
-
paste <(h task name -a) <(h task path -a) # name <-> path mapping
|
|
502
|
-
```
|
|
503
|
-
|
|
504
|
-
---
|
|
505
|
-
|
|
506
|
-
### session
|
|
507
|
-
|
|
508
|
-
Print the stored Herdr workspace label for a task. The `session` command name remains for compatibility. With no argument, it opens a fuzzyfind selector.
|
|
509
|
-
|
|
510
|
-
**Options**
|
|
511
|
-
|
|
512
|
-
| Flag | Short | Description | Default |
|
|
513
|
-
|------|-------|-------------|---------|
|
|
514
|
-
| `--task` | `-t` | Task name | current task |
|
|
515
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
516
|
-
| `--all` | `-a` | Print workspace label for every task; positional args become prefix filters (OR'd) | false |
|
|
517
|
-
|
|
518
|
-
**Examples**
|
|
519
|
-
|
|
520
|
-
```bash
|
|
521
|
-
h task session
|
|
522
|
-
h task session my-feature
|
|
523
|
-
h task session -a
|
|
524
|
-
```
|
|
525
|
-
|
|
526
|
-
---
|
|
527
|
-
|
|
528
|
-
### sh
|
|
529
|
-
|
|
530
|
-
Open a shell (or run a command) in the current task's worktree. With `--session`, create a new Herdr tab in the specified workspace.
|
|
531
|
-
|
|
532
|
-
**Options**
|
|
533
|
-
|
|
534
|
-
| Flag | Short | Description | Default |
|
|
535
|
-
|------|-------|-------------|---------|
|
|
536
|
-
| `--task` | `-t` | Task name | current task |
|
|
537
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
538
|
-
| `--session` | `-s` | Run in a new tab in this Herdr workspace | none |
|
|
539
|
-
|
|
540
|
-
**Examples**
|
|
541
|
-
|
|
542
|
-
```bash
|
|
543
|
-
h task sh
|
|
544
|
-
h task sh -t my-feature
|
|
545
|
-
h task sh my-feature bundle exec rails s
|
|
546
|
-
h task sh -s my-session
|
|
547
|
-
```
|
|
548
|
-
|
|
549
|
-
---
|
|
550
|
-
|
|
551
|
-
### sparse
|
|
552
|
-
|
|
553
|
-
Manage sparse checkout for the current task's worktree.
|
|
554
|
-
|
|
555
|
-
**Options**
|
|
556
|
-
|
|
557
|
-
| Flag | Short | Description |
|
|
558
|
-
|------|-------|-------------|
|
|
559
|
-
| `--list` | `-l` | List all configured sparse groups |
|
|
560
|
-
| `--disable` | `-d` | Disable sparse checkout on current task |
|
|
561
|
-
|
|
562
|
-
**Examples**
|
|
563
|
-
|
|
564
|
-
```bash
|
|
565
|
-
h task sparse # show active sparse checkout
|
|
566
|
-
h task sparse default # apply 'default' group
|
|
567
|
-
h task sparse -l # list all groups
|
|
568
|
-
h task sparse -d # disable sparse checkout
|
|
569
|
-
```
|
|
570
|
-
|
|
571
|
-
---
|
|
572
|
-
|
|
573
|
-
### start
|
|
574
|
-
|
|
575
|
-
Create a new task (worktree + Herdr workspace) and switch to it. If the task already exists, switch to it instead. Reuse an available unassigned worktree when possible; otherwise create a new one.
|
|
576
|
-
|
|
577
|
-
**Options**
|
|
578
|
-
|
|
579
|
-
| Flag | Short | Description | Default |
|
|
580
|
-
|------|-------|-------------|---------|
|
|
581
|
-
| `--sparse` | `-s` | Apply a sparse checkout group (repeatable) | none |
|
|
582
|
-
|
|
583
|
-
**Examples**
|
|
584
|
-
|
|
585
|
-
```bash
|
|
586
|
-
h task start my-feature
|
|
587
|
-
h task start my-feature api # open in app subdirectory
|
|
588
|
-
h task start my-feature -s default
|
|
589
|
-
```
|
|
590
|
-
|
|
591
|
-
---
|
|
592
|
-
|
|
593
|
-
### status / st
|
|
594
|
-
|
|
595
|
-
Show detailed info about the current task: name, worktree, path, workspace, and parent (if subtask).
|
|
596
|
-
|
|
597
|
-
**Examples**
|
|
598
|
-
|
|
599
|
-
```bash
|
|
600
|
-
h task status
|
|
601
|
-
h task st
|
|
602
|
-
```
|
|
603
|
-
|
|
604
|
-
---
|
|
605
|
-
|
|
606
|
-
### stop
|
|
607
|
-
|
|
608
|
-
Detach a task's worktree association and those of its subtasks. The task records, metadata, workspace labels, and resources remain. The former worktree path becomes a directory reference, and the worktree is available for reuse through `resume`. With no arguments, opens a fuzzyfind selector.
|
|
609
|
-
|
|
610
|
-
**Examples**
|
|
611
|
-
|
|
612
|
-
```bash
|
|
613
|
-
h task stop my-feature
|
|
614
|
-
h task stop
|
|
615
|
-
```
|
|
616
|
-
|
|
617
|
-
---
|
|
618
|
-
|
|
619
|
-
### switch
|
|
620
|
-
|
|
621
|
-
Switch to an existing task's Herdr workspace. With no arguments, open a fuzzyfind selector over tasks and workspaces. If the name matches a Herdr workspace rather than a task, focus it directly.
|
|
622
|
-
|
|
623
|
-
**Options**
|
|
624
|
-
|
|
625
|
-
| Flag | Short | Description | Default |
|
|
626
|
-
|------|-------|-------------|---------|
|
|
627
|
-
| `--force` | `-f` | Accepted for compatibility; Herdr workspace focus does not require it | false |
|
|
628
|
-
|
|
629
|
-
**Examples**
|
|
630
|
-
|
|
631
|
-
```bash
|
|
632
|
-
h task switch
|
|
633
|
-
h task switch my-feature
|
|
634
|
-
h task switch my-feature api
|
|
635
|
-
h task switch my-session -f
|
|
636
|
-
```
|
|
637
|
-
|
|
638
|
-
---
|
|
639
|
-
|
|
640
|
-
### tag
|
|
641
|
-
|
|
642
|
-
Add tags to a task. With `--edit`, opens a YAML editor for bulk tagging.
|
|
643
|
-
|
|
644
|
-
**Options**
|
|
645
|
-
|
|
646
|
-
| Flag | Short | Description |
|
|
647
|
-
|------|-------|-------------|
|
|
648
|
-
| `--edit` | `-e` | Open YAML editor to bulk-tag tasks |
|
|
649
|
-
|
|
650
|
-
**Examples**
|
|
651
|
-
|
|
652
|
-
```bash
|
|
653
|
-
h task tag my-feature urgent
|
|
654
|
-
h task tag my-feature api backend
|
|
655
|
-
h task tag -e
|
|
656
|
-
```
|
|
657
|
-
|
|
658
|
-
---
|
|
659
|
-
|
|
660
|
-
### tags
|
|
661
|
-
|
|
662
|
-
List all tagged tasks, grouped by tag.
|
|
663
|
-
|
|
664
|
-
**Examples**
|
|
665
|
-
|
|
666
|
-
```bash
|
|
667
|
-
h task tags
|
|
668
|
-
```
|
|
669
|
-
|
|
670
|
-
---
|
|
671
|
-
|
|
672
|
-
### todo
|
|
673
|
-
|
|
674
|
-
Manage todo items scoped to the current task. See [h-todo](h-todo.md) for the full todo system.
|
|
675
|
-
|
|
676
|
-
**Subcommands:** `ls`, `add`, `rm`, `start`, `done`, `skip`, `search`
|
|
677
|
-
|
|
678
|
-
**Examples**
|
|
679
|
-
|
|
680
|
-
```bash
|
|
681
|
-
h task todo
|
|
682
|
-
h task todo add "Fix the login bug"
|
|
683
|
-
h task todo add -t urgent "Refactor auth"
|
|
684
|
-
h task todo done 0
|
|
685
|
-
```
|
|
686
|
-
|
|
687
|
-
---
|
|
688
|
-
|
|
689
|
-
### tree
|
|
690
|
-
|
|
691
|
-
Print the worktree name for a task. With no argument, opens a fuzzyfind selector.
|
|
692
|
-
|
|
693
|
-
**Options**
|
|
694
|
-
|
|
695
|
-
| Flag | Short | Description | Default |
|
|
696
|
-
|------|-------|-------------|---------|
|
|
697
|
-
| `--task` | `-t` | Task name | current task |
|
|
698
|
-
| `--find` | `-f` | Choose task interactively | false |
|
|
699
|
-
| `--all` | `-a` | Print tree name for every task; positional args become prefix filters (OR'd) | false |
|
|
700
|
-
|
|
701
|
-
**Examples**
|
|
702
|
-
|
|
703
|
-
```bash
|
|
704
|
-
h task tree
|
|
705
|
-
h task tree my-feature
|
|
706
|
-
h task tree -a
|
|
707
|
-
h task tree -a feat bug
|
|
708
|
-
```
|
|
709
|
-
|
|
710
|
-
---
|
|
711
|
-
|
|
712
|
-
### untag
|
|
713
|
-
|
|
714
|
-
Remove tags from a task. With no tags, removes all tags.
|
|
715
|
-
|
|
716
|
-
**Examples**
|
|
717
|
-
|
|
718
|
-
```bash
|
|
719
|
-
h task untag my-feature urgent
|
|
720
|
-
h task untag my-feature # remove all tags
|
|
721
|
-
```
|
|
15
|
+
`h task` is the same program as `t`: `bin/h-task` is a symlink to `exe/t`, so `h task ARGS...` behaves exactly like `t ARGS...` with the task-first grammar above. `h subtask` is gone; a subtask is a task named `parent/child`, and `t tree new parent/child` creates its worktree under `~/work/parent/child`.
|
|
722
16
|
|
|
723
|
-
|
|
17
|
+
Worktree operations that used to live only under `h task` are now task commands:
|
|
724
18
|
|
|
725
|
-
|
|
19
|
+
| Old | Now |
|
|
20
|
+
|---|---|
|
|
21
|
+
| `h task start NAME [APP] [-s GROUP]` | `t tree new NAME [--app APP] [--sparse GROUP]` (creates the task record if needed, then the worktree, then the Herdr workspace) |
|
|
22
|
+
| `h task switch NAME [APP]` | `t switch NAME [--directory DIR]` |
|
|
23
|
+
| `h task stop NAME` | `t tree rm NAME` (detaches the worktree, keeps the directory, registers it as a directory resource) |
|
|
24
|
+
| `h task resume [TREE]` | `t tree resume NAME [TREE]` |
|
|
25
|
+
| `h task path`, `h task branch`, `h task tree` | `t path [TASK]`, `t branch [TASK]`, `t tree [TASK]` |
|
|
26
|
+
| `h task sh [CMD...]` | `t sh [TASK] [CMD...]` |
|
|
27
|
+
| `h task cd` | `t cd [TASK]` |
|
|
28
|
+
| `h task todo ...` | `t todo ... [TASK]` or `tt ...` |
|
|
29
|
+
| `h task ls` | `t ls` |
|
|
30
|
+
| `h task current` | `t current` |
|
|
31
|
+
| `h task queue`, `service`, `run`, `file` | `h queue`, `h service`, `h run`, `h file` |
|
|
726
32
|
|
|
727
|
-
|
|
33
|
+
`h task tag`, `untag`, `tags`, `sparse`, `from`, `prune`, `apps`, `save`, `status`, and `prs` were not carried over. Tag branches with `h branch tag`, inspect worktrees with `h wtree`, and register an existing directory with `t directory add [TASK] PATH --primary`.
|
|
728
34
|
|
|
729
|
-
|
|
35
|
+
`Hiiro::TaskManager` still holds the worktree creation code that `t tree new` and the shared `Hiiro::CurrentTask` resolver use; `h service`, `h run`, and `h file` keep using it for the current task through `Environment#task`, which now also recognizes a task by its home, primary directory, or registered directories.
|