Updated bitwarden-cli integration to mbsync
This commit is contained in:
parent
10ae6537a5
commit
6a3503794c
@ -1,10 +1,19 @@
|
||||
bw-init() {
|
||||
bw login --check &>/dev/null || return 0
|
||||
bw sync &>/dev/null || return 0
|
||||
|
||||
bw unlock --raw > $HOME/.bw_session
|
||||
}
|
||||
|
||||
bw-load() {
|
||||
export BW_SESSION=$(cat $HOME/.bw_session)
|
||||
}
|
||||
|
||||
bw-init() {
|
||||
if [ ! bw login --check &>/dev/null ]; then
|
||||
bw login
|
||||
fi
|
||||
|
||||
bw sync &>/dev/null || return 1
|
||||
bw-load
|
||||
|
||||
if [[ "$(bw status | jq -rc .status)" == "unlocked" ]]; then
|
||||
return 0
|
||||
fi
|
||||
|
||||
bw unlock --raw > $HOME/.bw_session
|
||||
bw-load
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
IMAPAccount gmail
|
||||
Host imap.gmail.com
|
||||
User jadenprovost@gmail.com
|
||||
PassCmd "export BW_SESSION=$(cat $HOME/.bw_session) && bw get password 'Emacs Gmail'"
|
||||
PassCmd "bw --session $(cat $HOME/.bw_session) --nointeraction get password 'Emacs Gmail'"
|
||||
SSLType IMAPS
|
||||
SSLVersions TLSv1.2
|
||||
AuthMechs PLAIN
|
||||
|
Loading…
x
Reference in New Issue
Block a user