Repository navigation
Complete log names for logs and task names for run - #48
Merged
Merged
Conversation
`logs` now completes its second positional arg with the *.log names in the target worktree's log dir, and `run` completes worktrees + task names for its first arg (mirroring splitRunArgs) and task names for the second when the first named a worktree. Task suggestions are sorted for stable output; any resolution failure degrades to no suggestions, as the worktree completion already did. Closes #31 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ws-dev logs <wt> <TAB>now suggests the*.logbasenames from the target worktree's log dir (same resolution as the command itself: config +$WS_DEV_LOG_DIR).ws-dev run <TAB>suggests worktree names and task names; after a worktree, the second arg suggests task names; after a task name, nothing (extra args are passthrough) — exactly mirroringsplitRunArgs.tasks:map has no order, so completion would otherwise jitter). Every failure path (unregistered repo, unresolvable worktree, missing log dir) degrades to "no suggestions", consistent with the existing worktree completion.ValidArgsFunctionfires despiterun'sDisableFlagParsingvia__completesmoke tests (worktree+tasks, tasks-after-worktree, none-after-task all behave).Closes #31
Test plan
TestTaskNames(prefix filtering + sorted output)__completesmoke tests against a throwaway$WS_DEV_CONFIGmake checkpasses🤖 Generated with Claude Code