fix(pilotctl): reject non-all skill ids in disable/enable (PILOT-394)#260
Merged
Conversation
cmdSkillsDisable and cmdSkillsEnable accept <skill-id|all> but ignore the argument — 'disable foo' and 'disable all' both run the global Uninstall. Since only one shared SKILL.md exists today, reject any id except 'all' with a clear error message directing users to use 'all' (the per-skill surface will be added in a future ticket). Changes: - cmdSkillsDisable: validate args[0] == 'all', error otherwise - cmdSkillsEnable: validate args[0] == 'all', error otherwise - Two new tests pinning the fix for non-all rejection Closes PILOT-394
TeoSlayer
reviewed
Jun 16, 2026
TeoSlayer
left a comment
Collaborator
There was a problem hiding this comment.
Debt acknowledged, TBD if per-skill is even relevant. Curated main skill feels more useful.
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.
What failed
pilotctl skills disableandpilotctl skills enableaccept<skill-id|all>but ignore the argument — both commands silently run the global Uninstall / re-enable.disable fooanddisable alldo the same thing.Why this fix
Since only one shared SKILL.md exists today, the pragmatic answer is to reject any id except
allwith a clear error. Per-skill enable/disable can be added in a future ticket when the skillinject library supports per-skill state.Changes
args[0] == "all", print error otherwiseargs[0] == "all", print error otherwiseVerification
go build ./cmd/pilotctl/— cleango vet ./cmd/pilotctl/— cleango test -count=1 ./cmd/pilotctl/— all pass (9.65s)make build— all 8 binaries build cleanlyTestCLISkillsDisable_RejectsNonAllandTestCLISkillsEnable_RejectsNonAlladdedCloses PILOT-394