mirror of
https://github.com/LukeSmithxyz/voidrice.git
synced 2026-03-20 01:37:45 +01:00
Change weird variable substitution
This commit is contained in:
parent
793cb61d7b
commit
3fbcb3d612
@ -3,15 +3,15 @@
|
||||
totp_tmp="${XDG_CACHE_HOME:-$HOME/.cache}/totp-tmp.png"
|
||||
|
||||
getPasswords() {
|
||||
choice="$(find "${PASSWORD_STORE_DIR--~/.password-store}" -type f | sed "s|${PASSWORD_STORE_DIR-~/.password-store}/|| ; s/.gpg$// ; /.gpg-id/d" | sort | grep -v "totp" | dmenu -i -p "Passwords")"
|
||||
choice="$(find "${PASSWORD_STORE_DIR:-$HOME/.password-store}" -type f | sed "s|${PASSWORD_STORE_DIR:-$HOME/.password-store}/|| ; s/.gpg$// ; /.gpg-id/d" | sort | grep -v "totp" | dmenu -i -p "Passwords")"
|
||||
|
||||
[ -z "$choice" ] && exit
|
||||
|
||||
pass -c "$choice" && notify-send "📋 Password for $choice copied!" || notify-send "⚠️ Something went wrong. Make sure you have initialized pass"
|
||||
}
|
||||
}
|
||||
|
||||
getTOTP() {
|
||||
choice="$(find "${PASSWORD_STORE_DIR--~/.password-store}" -type f | sed "s|${PASSWORD_STORE_DIR-~/.password-store}/|| ; s/.gpg$// ; /.gpg-id/d" | sort | grep "totp" | dmenu -i -p "OTP")"
|
||||
choice="$(find "${PASSWORD_STORE_DIR:-$HOME/.password-store}" -type f | sed "s|${PASSWORD_STORE_DIR:-$HOME/.password-store}/|| ; s/.gpg$// ; /.gpg-id/d" | sort | grep "totp" | dmenu -i -p "OTP")"
|
||||
|
||||
[ -z "$choice" ] && exit
|
||||
|
||||
@ -62,7 +62,7 @@ addPassword() {
|
||||
}
|
||||
|
||||
removePassword() {
|
||||
name="$(find "${PASSWORD_STORE_DIR--~/.password-store}" -type f | sed "s|${PASSWORD_STORE_DIR-~/.password-store}/|| ; s/.gpg$// ; /.gpg-id/d" | sort | dmenu -i -p "Passwords")"
|
||||
name="$(find "${PASSWORD_STORE_DIR:-$HOME/.password-store}" -type f | sed "s|${PASSWORD_STORE_DIR:-$HOME/.password-store}/|| ; s/.gpg$// ; /.gpg-id/d" | sort | dmenu -i -p "Passwords")"
|
||||
|
||||
[ -z "$name" ] && exit
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user