Skip to content

casonadams/bitwarden.zsh

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

bitwarden.zsh

Zsh plugin for quickly accessing Bitwarden secrets with auto-completion, caching, and TOTP support — securely and efficiently.

Features

  • Secure access to passwords and TOTP codes
  • Fast item lookup with tab-completion
  • Encrypted local cache of items (auto-refreshed every 6 hours)
  • Uses your existing Bitwarden CLI session if available
  • Minimal dependencies: bw, jq, oathtool (for TOTP)

Requirements


Installation

Using Zinit

zinit wait lucid for \
  casonadams/bitwarden.zsh

Using Oh My Zsh

ZSH_CUSTOM="${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}"
git clone https://github.com/casonadams/bitwarden.zsh.git "$ZSH_CUSTOM/plugins/bitwarden.zsh"

then add it to your .zshrc:

plugins+=(bitwarden.zsh)

Setup Tips

Having issues?

Try removing old cache files:

rm -f /tmp/.bw_items_cache* /tmp/.bw_session

Usage

Retrieve a password

bwpass github.com/[email protected]

Or use interactive auto-complete:

bwpass <TAB>

Retrieve a TOTP code

bwtotp github.com/[email protected]

Or interactively auto-complete:

bwtotp <TAB>

Examples

# Copy password for AWS
bwpass aws.amazon.com/[email protected]
# Copy TOTP for GitHub
bwtotp github.com/[email protected]
# View available entries
bwpass <TAB>
bwtotp <TAB>

Troubleshooting

  • Cache issues? Try: rm -f /tmp/.bw_*.

About

Bitwarden CLI zsh wrapper

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages