summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.hush4
-rwxr-xr-xbin/hush/p2
-rwxr-xr-xbin/hush/ssh-askpass2
-rwxr-xr-xbin/hush/sudo-askpass2
-rwxr-xr-xbin/on-lock1
-rw-r--r--config/msmtp/config2
-rw-r--r--config/offlineimap/config2
-rw-r--r--config/offlineimap/pass.py4
-rw-r--r--config/sh/aliases2
9 files changed, 11 insertions, 10 deletions
diff --git a/Makefile.hush b/Makefile.hush
index 972d92f..578eca0 100644
--- a/Makefile.hush
+++ b/Makefile.hush
@@ -60,8 +60,8 @@ config/alacritty/alacritty.yml : config/alacritty/alacritty.yml.hush
$(LN) $(notdir $<) $@
config/darksky/api :
- pass show websites/darksky.net/api > $@
+ rbw get darksky.net api > $@
mpdscribble/mpdscribble.conf : mpdscribble/mpdscribble.conf.tmpl
- pass="$$(pass show websites/last.fm/doyster)" &&\
+ pass="$$(rbw get last.fm doyster)" &&\
perl -E'while (<STDIN>) { if (/^password =/) { say "password = $$ARGV[0]" } else { print } }' "$$pass" < $< > $@
diff --git a/bin/hush/p b/bin/hush/p
index c2cbc9a..1b281ec 100755
--- a/bin/hush/p
+++ b/bin/hush/p
@@ -2,4 +2,4 @@
set -eu
set -o pipefail
-pass git ls-files | grep '\.gpg$' | sed 's/\.gpg$//' | fzf | xargs pass "$@"
+rbw ls --fields name,user | perl -pale'$_ .= "\t$F[0]/$F[1]"' | fzf --with-nth=3 | perl -pale's/\t[^\t]*$//' | xargs rbw get
diff --git a/bin/hush/ssh-askpass b/bin/hush/ssh-askpass
index 8088c8f..fe9e002 100755
--- a/bin/hush/ssh-askpass
+++ b/bin/hush/ssh-askpass
@@ -2,4 +2,4 @@
set -eu
set -o pipefail
-exec pass "ssh/$(hostname)"
+exec rbw get ssh hush
diff --git a/bin/hush/sudo-askpass b/bin/hush/sudo-askpass
index 2f487be..2f928ed 100755
--- a/bin/hush/sudo-askpass
+++ b/bin/hush/sudo-askpass
@@ -2,4 +2,4 @@
set -eu
set -o pipefail
-exec pass "system/$(hostname)/doy"
+exec rbw get "$(hostname)" doy
diff --git a/bin/on-lock b/bin/on-lock
index b9fa1fe..d7ee1f5 100755
--- a/bin/on-lock
+++ b/bin/on-lock
@@ -3,3 +3,4 @@
sudo -K
ssh-add -D
echo RELOADAGENT | gpg-connect-agent
+rbw lock
diff --git a/config/msmtp/config b/config/msmtp/config
index 77be9e9..6ceebb5 100644
--- a/config/msmtp/config
+++ b/config/msmtp/config
@@ -7,5 +7,5 @@ account default
host mail.tozt.net
from doy@tozt.net
user doy@tozt.net
-passwordeval pass "websites/mail.tozt.net/doy@tozt.net"
+passwordeval rbw get mail.tozt.net doy@tozt.net
tls_trust_file /etc/ssl/certs/ca-certificates.crt
diff --git a/config/offlineimap/config b/config/offlineimap/config
index a5531a0..fd9110a 100644
--- a/config/offlineimap/config
+++ b/config/offlineimap/config
@@ -23,7 +23,7 @@ ssl = yes
sslcacertfile = /etc/ssl/certs/ca-certificates.crt
remotehost = mail.tozt.net
remoteuser = doy@tozt.net
-remotepasseval = get_password("websites/mail.tozt.net/doy@tozt.net")
+remotepasseval = get_password("mail.tozt.net", "doy@tozt.net")
maxconnections = 5
keepalive = 60
holdconnectionopen = yes
diff --git a/config/offlineimap/pass.py b/config/offlineimap/pass.py
index 20ca510..6a7fba3 100644
--- a/config/offlineimap/pass.py
+++ b/config/offlineimap/pass.py
@@ -1,5 +1,5 @@
from subprocess import Popen, PIPE
-def get_password(key):
- (out, err) = Popen(["pass", key], stdout=PIPE).communicate()
+def get_password(name, user):
+ (out, err) = Popen(["rbw", "get", name, user], stdout=PIPE).communicate()
return out.strip()
diff --git a/config/sh/aliases b/config/sh/aliases
index ecef8d7..ffe1ec9 100644
--- a/config/sh/aliases
+++ b/config/sh/aliases
@@ -35,7 +35,7 @@ alias v="vim --cmd 'let g:startify_disable_at_vimenter = 1' -c 'call feedkeys(\"
alias g="vim --cmd 'let g:startify_disable_at_vimenter = 1' -c 'call feedkeys(\"ff\")'"
alias utc="env TZ=UTC date"
alias pd="perldoc"
-alias pc="p -c"
+alias pc="p | xclip -l 1"
# }}}
# vim:ft=sh:fdm=marker