Skip to content

Convert the shell's remaining hand-parsed flags to real flags #89

Description

@kanushka

Parent

#85

What to build

The flags the shell's built-in commands still parse by hand become real flags, so they behave the way every other flag in the CLI does. The release channel flag on module installation, the update-everything flag, and the non-interactive login flag all gain the spellings a user expects — an equals form, a negatable boolean where that reads naturally, and a clear error when a value is missing rather than a hand-written special case.

This is the only user-visible parsing change in #85, which is why it is its own ticket. A user who has been writing these flags in the one spelling that previously worked keeps working; what changes is that the spellings that previously failed now succeed, and the failures that remain are reported uniformly with recovery guidance and the usage exit class.

After this, no shell command scans its own argument list. The only remaining hand-written argument handling in the shell is at the product namespace boundary, which is deliberate and is removed by #86.

Acceptance criteria

  • The release channel, update-all, and non-interactive flags are declared as flags rather than scanned by hand
  • Each accepts both the separated and the equals spelling
  • A missing flag value reports a typed usage problem with recovery guidance and the usage exit class
  • Naming a module together with the update-everything flag is still refused as ambiguous, with the same problem code as today
  • The hand-written argument scanning loops in the built-in command bodies are deleted
  • Existing tests for these commands pass, updated only where the change is the intended user-visible one
  • No shell built-in command scans its own argument list; the product namespace boundary is the only hand-written argument handling left

Blocked by

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type/ImprovementMarks enhancements or improvements to existing featuresready-for-agentFully specified and ready for implementation by an agent

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions