Skip to content

Conversation

@johnbute
Copy link
Contributor

@johnbute johnbute commented Oct 23, 2025

Modified swift package --help in order to include possible commands provided by command plugins

Motivation:

Fixes #9226

Modifications:

Overrode --help and -h of swift package command to also include, after printing the help message, the output of swift package plugin --list

Added tests to support change too

Result:

After --help message is printed, users will see a new section (whenever needed) called AVAILABLE PLUGIN COMMANDS:

`
completion-tool Command to generate shell completions.
plugin Invoke a command plugin or perform other actions on command plugins.

See 'swift help package ' for detailed help.

AVAILABLE PLUGIN COMMANDS:
benchmark (plugin ‘BenchmarkCommandPlugin’ in package ‘Benchmark’)
`

…e --help causes bug where --help is not recognized by subcommands
@johnbute
Copy link
Contributor Author

@swift-ci please test

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

Labels

None yet

1 participant