diff options
| author | Paul Buetow <paul@buetow.org> | 2026-04-07 09:06:35 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-04-07 09:06:35 +0300 |
| commit | 4185a422395bfe9d40c6f934fd56663d223bf782 (patch) | |
| tree | 824096882989869fd65643b45c49a6c5bae11b00 /integrationtests | |
| parent | 627485ecf12991c08340c69c999a117dfb24eebb (diff) | |
feat: show task summary in fish shell autocompletion for alias IDs
The complete-uuids command now emits tab-separated "selector\tdescription"
lines so fish shell displays the first 60 chars of the task description
alongside each alias/UUID in the autocompletion menu. The
__ask_add_dependency_modifiers fish function is updated to strip the
description field before matching and building depends: completions.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'integrationtests')
| -rw-r--r-- | integrationtests/ask_scope_test.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/integrationtests/ask_scope_test.go b/integrationtests/ask_scope_test.go index ef77757..a328881 100644 --- a/integrationtests/ask_scope_test.go +++ b/integrationtests/ask_scope_test.go @@ -75,9 +75,14 @@ func hasTag(tags []string, want string) bool { return false } +// hasSelectorLine reports whether any line in output starts with want followed +// by a tab or end-of-line. This handles the "selector\tdescription" format +// emitted by complete-uuids for fish shell autocompletion. func hasSelectorLine(output, want string) bool { for _, line := range strings.Split(strings.TrimSpace(output), "\n") { - if strings.TrimSpace(line) == want { + line = strings.TrimSpace(line) + // Accept exact match (no description) or tab-prefixed description. + if line == want || strings.HasPrefix(line, want+"\t") { return true } } |
