-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
Prebuilt binaries — download from GitHub Releases. Archives, MSI (Windows), and shell installers are available for Linux, macOS, and Windows.
From crates.io:
cargo install rpass-cliThe installed binary is rpass.
rpass delegates all encryption to your system's GnuPG installation.
| Platform | Command |
|---|---|
| macOS | brew install gnupg |
| Ubuntu/Debian | sudo apt install gnupg |
| Fedora/RHEL | sudo dnf install gnupg2 |
| Windows | Install Gpg4win |
Verify: gpg --version should print gpg (GnuPG) 2.x.
If you already have a GPG key you want to use, skip this step.
gpg --full-generate-keyChoose RSA and RSA, 4096 bits, and enter your name and email. When done, find your key ID:
gpg --list-secret-keys --keyid-format LONGThe key ID is the long hex string after rsa4096/, or you can use the email you registered.
rpass init you@example.comThis creates ~/.password-store/.gpg-id with your key ID. All entries in the store will be encrypted for that key.
Use a custom directory:
rpass --store-dir ~/my-store init you@example.comOr set the environment variable permanently:
export PASSWORD_STORE_DIR=~/my-storeMultiple recipients (e.g. you + a team member):
rpass init you@example.com teammate@example.comBoth of you can decrypt any entry. Each person uses their own private key.
Subfolder recipients (different key for a specific folder):
rpass init --path work work-key@example.comEntries under work/ will be encrypted for work-key@example.com instead of the root recipient.
Interactive prompt:
rpass insert email/workrpass will ask for the password (input is hidden).
Multiline entry (password on first line, metadata below):
s3cr3t-p4ssword
username: alice
url: https://mail.example.com
From stdin (non-interactive):
echo "my-password" | rpass insert email/workrpass show email/workOutput:
s3cr3t-p4ssword
username: alice
url: https://mail.example.com
As JSON:
rpass show email/work --json{
"entry": "email/work",
"password": "s3cr3t-p4ssword",
"fields": [
{ "name": "username", "value": "alice" },
{ "name": "url", "value": "https://mail.example.com" }
]
}rpass list
rpass list --jsonrpass generate email/work # generate a random 14-character password
rpass edit email/work # open entry in $EDITOR
rpass mv email/work archive/work # move or rename
rpass rm email/work # remove
rpass otp email/totp # generate TOTP code (entry must have otpauth:// line)rpass commits automatically after every write command. To run git commands manually:
rpass git status
rpass git log
rpass git remote add origin git@github.com:you/pass-store.git
rpass git pushrpass completions bash >> ~/.bashrc
rpass completions zsh > "${fpath[1]}/_rpass"
rpass completions fish > ~/.config/fish/completions/rpass.fish
rpass completions powershell >> $PROFILErpass doctorReports GPG version, store location, key availability, and git status.
For scripts and CI, pass the GPG passphrase via stdin:
printf 'my-gpg-passphrase\n' | rpass show email/work --json --passphrase-stdin