diff options
author | Jesse Luehrs <doy@tozt.net> | 2020-05-04 00:06:41 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2020-05-04 00:06:41 -0400 |
commit | eb82836e5f2972c7a9bf8982af987b645140fc40 (patch) | |
tree | 28b2f621a44e0348650307780484e3f22cc28b00 /bin | |
parent | 1f8c162426ef022cb1a884851b3fa64ff807d8a0 (diff) | |
download | conf-eb82836e5f2972c7a9bf8982af987b645140fc40.tar.gz conf-eb82836e5f2972c7a9bf8982af987b645140fc40.zip |
include folders when picking passwords
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/hush/p | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ -#!/bin/sh +#!/bin/bash set -eu set -o pipefail -rbw ls --fields name,user | perl -pale'$_ = "$F[0]/$F[1]\t$_"' | fzf --with-nth=1 | perl -pale's/^[^\t]*\t//' | xargs -r rbw get +rbw ls --fields name,user,folder | perl -plE'/^([^\t]*)\t([^\t]*)\t([^\t]*)$/; $_ = join("/", grep { length } ($3, $1, $2)) . "\t$_"' | sort | fzf --with-nth=1 | perl -ple'/^([^\t]*)\t([^\t]*)\t([^\t]*)\t([^\t]*)$/; $_ = "$2 $3"' | xargs -r rbw get |