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

refactor: use urfave/cli instead of yitsushi/go-commander #79

Merged
merged 2 commits into from
Jul 18, 2023
Merged

Conversation

yitsushi
Copy link
Owner

My CLI lib1 was a good exercise and an experiment2 7 years ago. Back then, I did not plan to use it that long.

I tried to keep the interface the same as it was before. Some changed, but I don't think anyone will notice as only dump and import changes.

  • The import command now requires an --input flag instead of a positional argument.
  • The dump command now required a --yes-please flag to make sure the user understands that the exported content will NOT be encrypted.
  • The dump command now requires an --output flag, stdout is not the default behaviour. If someone really wants to dump secrets to stdout... Well, you can use --output=/dev/stdout.

Bug fixes:

  • Import did not import Prefix on overwrite.

Closes #39

Footnotes

  1. https://github.com/yitsushi/go-commander

  2. https://github.com/yitsushi/totp-cli/issues/78#issuecomment-1639523393

My CLI lib[^1] was a good exercise and an experiment[^2] 7 years ago. Back
then, I did not plan to use it that long.

I tried to keep the interface the same as it was before. Some changed,
but I don't think anyone will notice as only `dump` and `import`
changes.

* The `import` command now requires an `--input` flag instead of a
  positional argument.
* The `dump` command now required a `--yes-please` flag to make sure the
  user understands that the exported content will NOT be encrypted.
* The `dump` command now requires an `--output` flag, stdout is not the
  default behaviour. If someone really wants to dump secrets to
  stdout... Well, you can use `--output=/dev/stdout`.

Bug fixes:
* Import did not import Prefix on overwrite.

Closes #39

[^1]: https://github.com/yitsushi/go-commander
[^2]: #78 (comment)

Signed-off-by: Efertone <efertone@pm.me>
Signed-off-by: Efertone <efertone@pm.me>
@yitsushi yitsushi merged commit fc57e41 into main Jul 18, 2023
8 checks passed
@yitsushi yitsushi deleted the use-urfave branch July 18, 2023 08:36
@yitsushi
Copy link
Owner Author

This fixed #78 too 🥳

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.

use urfave instead of my own go-commander
1 participant