Commit c2f2e1d

xxwhirlpool  ·  2025-12-18 16:13:55 -0500 EST
parent c22d9cd
add passmenu & tempmenu
4 files changed,  +54, -6
+1, -0
......@@ -135,6 +135,7 @@ alias cat="bat --paging=never"
135135 alias rced="micro ~/.bashrc && source ~/.bashrc"
136136 alias dd="askdd"
137137 alias copy="xclip -sel clipboard"
138+alias calc="python3 -Sq"
138139
139140 # lazy ass way for me to get my idol mp3s from youtube
140141 # usage: ytmp3 url
+0, -6
......@@ -1968,12 +1968,6 @@
19681968 ๐Ÿคž๐Ÿฝ crossed fingers: medium skin tone
19691969 ๐Ÿคž๐Ÿพ crossed fingers: medium-dark skin tone
19701970 ๐Ÿคž๐Ÿฟ crossed fingers: dark skin tone
1971-๐Ÿ–– vulcan salute
1972-๐Ÿ––๐Ÿป vulcan salute: light skin tone
1973-๐Ÿ––๐Ÿผ vulcan salute: medium-light skin tone
1974-๐Ÿ––๐Ÿฝ vulcan salute: medium skin tone
1975-๐Ÿ––๐Ÿพ vulcan salute: medium-dark skin tone
1976-๐Ÿ––๐Ÿฟ vulcan salute: dark skin tone
19771971 ๐Ÿค˜ sign of the horns
19781972 ๐Ÿค˜๐Ÿป sign of the horns: light skin tone
19791973 ๐Ÿค˜๐Ÿผ sign of the horns: medium-light skin tone
+24, -0
......@@ -0,0 +1,24 @@
1+#!/usr/bin/env bash
2+
3+shopt -s nullglob globstar
4+
5+typeit=0
6+if [[ $1 == "--type" ]]; then
7+ typeit=1
8+ shift
9+fi
10+
11+prefix=${PASSWORD_STORE_DIR-~/.password-store}
12+password_files=( "$prefix"/**/*.gpg )
13+password_files=( "${password_files[@]#"$prefix"/}" )
14+password_files=( "${password_files[@]%.gpg}" )
15+
16+password=$(printf '%s\n' "${password_files[@]}" | dmenu -i -c -l 10 "$@")
17+
18+[[ -n $password ]] || exit
19+
20+if [[ $typeit -eq 0 ]]; then
21+ pass show -c "$password" 2>/dev/null
22+else
23+ pass show "$password" | { IFS= read -r pass; printf %s "$pass"; } | $xdotool
24+fi
+29, -0
......@@ -0,0 +1,29 @@
1+#!/bin/bash
2+
3+f_to_c() {
4+ fah=$(echo "" | dmenu -i -c -l 3 -p 'enter temp in fahrenheit')
5+ cel=$(bc <<< "scale=2; ($fah - 32) * 5/9")
6+ result="$fahยฐF is equal to $celยฐC"
7+ notify-send "$result"
8+}
9+
10+c_to_f() {
11+ cel=$(echo "" | dmenu -i -c -l 3 -p 'enter temp in celsius')
12+ fah=$(bc <<< "scale=2; ($cel * 9/5) + 32")
13+ result="$celยฐC is equal to $fahยฐF"
14+ notify-send "$result"
15+}
16+
17+menu() {
18+ cmd=$(printf "fahrenheit to celsius\\ncelsius to fahrenheit" | dmenu -i -c -l 10 -p "temperature conversion")
19+ case "$cmd" in
20+ *celsius) f_to_c ;;
21+ *fahrenheit) c_to_f ;;
22+ *) exit 0;;
23+ esac
24+}
25+
26+case "$1" in
27+ *menu) menu ;;
28+ *) exit;;
29+esac