Skip to content

Commit

Permalink
enchanced examples for 2fa command + readme update 📝
Browse files Browse the repository at this point in the history
  • Loading branch information
jenish-jain committed Nov 5, 2023
1 parent c664b8a commit 3b50f72
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions cmd/2fa.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ var twoFACmd = &cobra.Command{
Use: "2fa",
Short: "cli tool to manage your internal codes",
Long: "This tool helps you manage your 2FA codes both hotp and totp",
Example: "sidekick 2fa -a [-7] [-8] [-hotp] github \\n \n" +
"sidekick 2fa -l \n" +
"sidekick 2fa github \n" +
"sidekick 2fa \n" +
"sidekick 2fa -c github \n" +
"sidekick 2fa -h \n",
Run: func(cmd *cobra.Command, args []string) {
twoFA.HandleCommand(cmd, args)
},
Expand Down
2 changes: 1 addition & 1 deletion internal/twoFA/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Learn more about this: https://www.rfc-editor.org/rfc/rfc4226
| NONE | NA | prints a two-factor authentication code for all key or specified name. | <ul><li>`sidekick 2fa <name>`</li><li>`sidekick 2fa`</li></ul> |

* The default time-based authentication codes are derived from a hash of the key and the current time, so it is important that the system clock have at least one-minute accuracy.

* while displaying the code, it also displays the sec code can be refreshed next in, -1 indicated no expiry till next usage
* The keychain is stored unencrypted in the text file $HOME/.2fa.

## Example
Expand Down

0 comments on commit 3b50f72

Please sign in to comment.