diff options
| author | TheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com> | 2025-02-07 13:02:03 +0900 |
|---|---|---|
| committer | TheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com> | 2025-02-07 13:02:03 +0900 |
| commit | 8b53277b492831109a1e1a8d7d4c5753d9d48fa2 (patch) | |
| tree | 0c5c26837160f223a762aa9ef48cbff3149e6143 /ar/.local/bin/getkeys | |
| parent | 83487d66031d2576f7336de20f0900b7264a391b (diff) | |
modified bin/bookmarks, modified bin/dmenuconnections, modified bin/getkeys, modified bin/qndl, modified statusbar/sb-internet
Diffstat (limited to 'ar/.local/bin/getkeys')
| -rwxr-xr-x | ar/.local/bin/getkeys | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ar/.local/bin/getkeys b/ar/.local/bin/getkeys index 79a7872..492b056 100755 --- a/ar/.local/bin/getkeys +++ b/ar/.local/bin/getkeys @@ -1,6 +1,7 @@ #!/bin/sh # Print available keys from thesiah -cat "${XDG_DATA_HOME:-${HOME}/.local/share}"/thesiah/keys/"$1" 2>/dev/null && exit -echo "Run command with one of the following arguments for info about that program:" -ls "${XDG_DATA_HOME:-${HOME}/.local/share}"/thesiah/keys +[ -n "$1" ] && cat "${XDG_DATA_HOME:-${HOME}/.local/share}"/thesiah/keys/"$1" 2>/dev/null && exit +keys_dir="${XDG_DATA_HOME:-${HOME}/.local/share}/thesiah/keys" +selected_file=$(du -a "$keys_dir" | cut -f2- | sed "s|$keys_dir/||" | fzf) +[ -n "$selected_file" ] && cat "$keys_dir/$selected_file" |
