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

Add shorthand letter to flags #32

Open
sylviamoss opened this issue Feb 11, 2024 · 0 comments
Open

Add shorthand letter to flags #32

sylviamoss opened this issue Feb 11, 2024 · 0 comments

Comments

@sylviamoss
Copy link
Owner

Add shorthand options to flags. For example,

diceware-cli generate --size=4 --copy  

It could be shortened to:

diceware-cli generate -s=4 -c

To achieve that, the Flags method should be updated to use the suffixed P version.

--  generateCmd.Flags().StringVar(&dicewareConfig.Lang, "lang", "en", "password language\n available langs: en, pt")
++ generateCmd.Flags().StringVarP(&dicewareConfig.Lang, "lang", "l", "en", "password language\n available langs: en, pt")
@sylviamoss sylviamoss converted this from a draft issue Feb 11, 2024
@sylviamoss sylviamoss moved this from Backlog to Ready in Diceware CLI Feb 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Ready
Development

No branches or pull requests

1 participant