Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplified version flag. #82

Merged
merged 10 commits into from
Jul 12, 2022
Merged

Simplified version flag. #82

merged 10 commits into from
Jul 12, 2022

Conversation

ValleyZw
Copy link
Contributor

  • Used cobra Version for simplicity: 'A shorthand "v" flag will also be added if the command does not define one.'
  • Removed original version flag.

@ganigeorgiev
Copy link
Member

There were 2 reasons why I din't use the Version of the command:

  • I wanted it to have the same API as for example go run version
  • the --version flag is not passed by default to the child commands (which is inconsistent with the other global flags)`

But on second thought, I think as it is in the PR maybe is better because its a lot more simple and this way users will have the option to change the printed name of the application more easily since they'd have access to PocketBase.RootCmd.Use (additionally we may want to remove the (untracked text) and leave it empty by default, I'll think a little more on this later).

@ganigeorgiev ganigeorgiev merged commit ce85798 into pocketbase:master Jul 12, 2022
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.

None yet

2 participants