dotfiles/mutt/.mutt/unlock-pass.sh
Frank Villaro-Dixon b9bac31d4a using stow nowe
2016-06-13 12:11:18 +02:00

17 lines
294 B
Bash
Executable file

#!/bin/bash
#Unlock pass - clever version
#On ecryptfs
PASS_FILE=~/.mutt/passwords_decrypted
#PASS_FILE="/dev/shm/$USER-mutt-pass"
#ENC_PASS_FILE=~/.mutt/passwords.gpg
if [ ! -s $PASS_FILE ]; then
umask 077
gpg -d $ENC_PASS_FILE > $PASS_FILE
fi
cat $PASS_FILE | grep $1 | cut -d"=" -f2