Skip to content

Commit 0c4574e

Browse files
committed
docs: add some examples to README.md
1 parent 01bc097 commit 0c4574e

File tree

1 file changed

+22
-26
lines changed

1 file changed

+22
-26
lines changed

README.md

Lines changed: 22 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -13,36 +13,39 @@ minimalist, secure, desktop accessible software to manage my two-factor authenti
1313

1414
## Interface
1515

16-
cotp is written with simplicity in mind, the interface is quite minimalist and intuitive as command line apps should be.
17-
1816
[![asciicast](https://asciinema.org/a/459912.svg)](https://asciinema.org/a/459912)
1917

20-
If you are familiar with the command line interface using cotp will not be a problem. Just type `cotp` to enter the TUI
21-
dashboard. Type `i` to get some instruction. Otherwise just enter `cotp --help`.
22-
18+
Type `i` to get some instruction. Otherwise just enter `cotp --help`.
2319
In the first run you will be prompted to insert a password to initialize the database.
2420

25-
## Basic functionalities
21+
## TL;DR
22+
```bash
23+
# Display all the OTP codes in the interactivee dashboard
24+
cotp
2625

27-
### Display all the OTP codes in the interactivee dashboard
26+
# Add a new TOTP code from a BASE32 secret key
27+
cotp add -l <label> -i <optional_issuer>
2828

29-
```
30-
cotp
31-
```
29+
# Add a new HOTP code with custom algorithm and digits
30+
cotp add --type hotp --algorithm SHA256 -d 8 --counter 10
3231

33-
### Add a new TOTP code from a BASE32 secret key
32+
# Edit the digits of the 4th code
33+
cotp edit -i 4 --digits 8
3434

35-
```
36-
cotp add -l <label> -i <optional_issuer>
37-
Password: <insert your database password>
38-
Insert the secret: <BASE32 secret>
35+
# List all the codes in json format passing password through stdin
36+
echo "mysecretpassword" | cotp --password-stdin list --json
37+
38+
# Import an encrypted Aegis Database backup
39+
cotp import --path my_db.json --aegis-encrypted
3940
```
4041

41-
### Add a new HOTP code with custom algorithm and digits
42+
## Compatibility
4243

43-
```
44-
cotp add --type hotp --algorithm SHA256 -d 8 --counter 10
45-
```
44+
cotp can generate both **TOTP** and **HOTP** codes, compliant with **rfc6238** and **rfc4226** specifications. Also, it
45+
is possible to customize settings like **HMAC algorithm** and **digits**, to provide compatibility to other two-factor
46+
authentication systems.
47+
48+
Latest releases also include support for Steam, Yandex, MOTP codes and code copying from SSH Remote Shell.
4649

4750
BASE32 secret will be prompted as usual
4851

@@ -54,13 +57,6 @@ and [Argon2id](https://en.wikipedia.org/wiki/Argon2) for key derivation.
5457

5558
It also uses [AES-GCM](https://docs.rs/aes-gcm/latest/aes_gcm/) to import from encrypted Aegis backups.
5659

57-
## Compatibility
58-
59-
cotp can generate both **TOTP** and **HOTP** codes, compliant with **rfc6238** and **rfc4226** specifications. Also, it
60-
is possible to customize settings like **HMAC algorithm** and **digits**, to provide compatibility to other two-factor
61-
authentication systems.
62-
63-
Latest releases also include support for Steam, Yandex, MOTP codes and code copying from SSH Remote Shell.
6460

6561
## Cross Plaform
6662

0 commit comments

Comments
 (0)