From b20b6f7263f6e3d9302b8ee5eb559a5ad9ab7c57 Mon Sep 17 00:00:00 2001 From: pagedmov Date: Tue, 15 Oct 2024 10:36:48 -0400 Subject: [PATCH] (laptop) Gen 21: removed passhelper.sh and reduced sleep time in passhelper script --- flake.lock | 12 ++++++------ modules/home/scripts/wm-controls/passhelper.nix | 2 +- modules/home/scripts/wm-controls/passhelper.sh | 17 ----------------- 3 files changed, 7 insertions(+), 24 deletions(-) delete mode 100755 modules/home/scripts/wm-controls/passhelper.sh diff --git a/flake.lock b/flake.lock index ee89fa7..e92feee 100644 --- a/flake.lock +++ b/flake.lock @@ -825,11 +825,11 @@ }, "nur": { "locked": { - "lastModified": 1728930569, - "narHash": "sha256-OvKCDKpI8sHA07Ct+f5uotGr9ATrIJ/fUfwZZnD8Tmk=", + "lastModified": 1728998640, + "narHash": "sha256-mbtviOFtza3J6e2wlkqICSj0PcqEsPpAlPuVnvLBAfM=", "owner": "nix-community", "repo": "NUR", - "rev": "96670f5e62fc211ff06be5ed7654c44318ddf7e2", + "rev": "9c76575706ddbe8b71b8dee7c399d7dba2141635", "type": "github" }, "original": { @@ -952,11 +952,11 @@ ] }, "locked": { - "lastModified": 1728879439, - "narHash": "sha256-spvD0mgjj0xMv4qinSl5lxGLe8V8JAeIWNs0HF0i3kE=", + "lastModified": 1728965841, + "narHash": "sha256-IwFh7KUJ9saIONcklEkXR3ANtGxkZsNdtpeT6eyF01Q=", "owner": "gerg-l", "repo": "spicetify-nix", - "rev": "c3463a8497fef3150aa8635d32b61b16e17a1e6b", + "rev": "3dfd050f21568902449939f085e8d1aa28fb9913", "type": "github" }, "original": { diff --git a/modules/home/scripts/wm-controls/passhelper.nix b/modules/home/scripts/wm-controls/passhelper.nix index 9b36b97..3dca801 100644 --- a/modules/home/scripts/wm-controls/passhelper.nix +++ b/modules/home/scripts/wm-controls/passhelper.nix @@ -15,6 +15,6 @@ pass_string=$(find $HOME/.password-store -type f | sed 's|.*/.password-store/||; # pass it through fmt for soft word wrapping pass -c "$pass_string" | fmt -w 45 /run/current-system/sw/bin/rm /tmp/passhelperfile -sleep 1.5 +sleep 0.5 exit 0 '') diff --git a/modules/home/scripts/wm-controls/passhelper.sh b/modules/home/scripts/wm-controls/passhelper.sh deleted file mode 100755 index 764ed5c..0000000 --- a/modules/home/scripts/wm-controls/passhelper.sh +++ /dev/null @@ -1,17 +0,0 @@ - -#!/run/current-system/sw/bin/bash - - # prevent multiple instances, conditional check happens in the hyprland bind -touch /tmp/passhelperfile -trap "[ -f /tmp/passhelperfile ] && /run/current-system/sw/bin/rm /tmp/passhelperfile" EXIT SIGHUP SIGINT - - # get passwords from password store, remove .password store/ prefix and .gpg suffix, exlude .gpg-id file, open results in fzf -pass_string=$(find $HOME/.password-store -type f | sed 's|.*/.password-store/||; s|\.gpg$||' | sed 's|^\([^/]*\)|\x1b[32m\1\x1b[0m|' | rg -v "\.git|.gpg-id" | sort -r | fzf --border --border-label="$(whoami)'s keyring" --ansi --layout=reverse) - -[ $? = 0 ] || { [ -f /tmp/passhelperfile ] && /run/current-system/sw/bin/rm /tmp/passhelperfile; exit 1; } - - # pass it through fmt for soft word wrapping -pass -c "$pass_string" | fmt -w 45 -/run/current-system/sw/bin/rm /tmp/passhelperfile -sleep 10 -exit 0