summaryrefslogtreecommitdiffstatshomepage
path: root/rofi/.local/bin/rofi-ykman
diff options
context:
space:
mode:
authorToby Vincent <tobyv@tobyvin.dev>2023-07-22 16:25:36 -0500
committerToby Vincent <tobyv@tobyvin.dev>2023-07-22 16:25:36 -0500
commit24070b249faf104af7915d5bcca1f5949cf3a4e9 (patch)
treeda0f8aef0f4be2d1422b47d35b9e7c2fd7fcd89d /rofi/.local/bin/rofi-ykman
parentdc35691ecf7aa36ab916bbb9634a75e0e1a747e0 (diff)
feat(sway): replace rofi with bemenu
Diffstat (limited to 'rofi/.local/bin/rofi-ykman')
-rwxr-xr-xrofi/.local/bin/rofi-ykman33
1 files changed, 0 insertions, 33 deletions
diff --git a/rofi/.local/bin/rofi-ykman b/rofi/.local/bin/rofi-ykman
deleted file mode 100755
index 3d4ca99..0000000
--- a/rofi/.local/bin/rofi-ykman
+++ /dev/null
@@ -1,33 +0,0 @@
-#!/usr/bin/env bash
-
-# rofi-ykman
-# Yubikey oath utility
-
-#2019 nukeop
-
-if [ ! "$(ykman info)" ]; then
- notify-send "rofi-ykman" "Yubikey not detected." -a "rofi-ykman"
- exit 1
-fi
-
-OPTIONS=$(ykman oath accounts list)
-LAUNCHER="rofi -dmenu -i -p YubikeyOATH"
-
-option=$(echo "${OPTIONS/, TOTP/\n}" | $LAUNCHER)
-code=$(ykman oath accounts code "$option")
-IFS=', ' read -r -a code <<<"$code"
-if [ "$XDG_SESSION_TYPE" == "wayland" ]; then
- cliptool=wl-copy
- typer="wtype -"
-else
- cliptool="xclip -selection clipboard"
- typer="xargs xdotool type"
-fi
-if [ "$1" == "type" ]; then
- action=$typer
-else
- action=$cliptool
-fi
-
-notify-send "rofi-ykman" "Touch Yubikey..." -a "rofi-ykman"
-echo "${code[-1]}" | $action