citty icon indicating copy to clipboard operation
citty copied to clipboard

A way to override `--version`

Open igalklebanov opened this issue 1 year ago • 2 comments

Describe the feature

Hey 👋

❤️ citty!

I've implemented a custom version flag (aliased as v) and logic that prints versions of multiple packages. It seems that the built-in version flag logic overrides my flag logic and fails since I don't pass a version prop in the root command's meta object.

Doesn't seem like a bug, more like a behavior that needs enhancement - the ability to override the default behavior of --version.

WDYT?

Additional information

  • [x] Would you be willing to help implement this feature?

igalklebanov avatar May 17 '24 09:05 igalklebanov

Can you provide a reproduction please 😄

zuixinwang avatar Jul 15 '24 10:07 zuixinwang

(reproduction is not needed 👍🏼)

pi0 avatar Jul 16 '24 16:07 pi0