Skip to content

command.go: fix flag ordering when only persistent flags disable SortFlags#2419

Open
egr3s wants to merge 1 commit into
spf13:mainfrom
egr3s:issue1033
Open

command.go: fix flag ordering when only persistent flags disable SortFlags#2419
egr3s wants to merge 1 commit into
spf13:mainfrom
egr3s:issue1033

Conversation

@egr3s

@egr3s egr3s commented Jun 13, 2026

Copy link
Copy Markdown

Fixes #1033

LocalFlags() now respects PersistentFlags().SortFlags and adds persistent flags from their own flag set so help output preserves definition order.

Co-authored-by: Cursor cursoragent@cursor.com

…Flags

Fixes spf13#1033

LocalFlags() now respects PersistentFlags().SortFlags and adds persistent flags from their own flag set so help output preserves definition order.

Co-authored-by: Cursor <cursoragent@cursor.com>
@CLAassistant

CLAassistant commented Jun 13, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@egr3s
egr3s marked this pull request as ready for review June 13, 2026 13:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Persistent flags alone can't disable the ordering properly

2 participants