calc migration
This commit is contained in:
@@ -3,13 +3,13 @@
|
||||
shift
|
||||
query="$1"
|
||||
if [ -z "$query" ]; then
|
||||
query="$(echo "tui" | bemenu --prompt "qalc")"
|
||||
query="$(echo "tui" | ~/.local/bin/menu/horizontal.sh -p "qalc")"
|
||||
fi
|
||||
if [ "$query" = "tui" ]; then
|
||||
exec alacritty msg create-window --class="term_float" --working-directory="$HOME" --command "qalc"
|
||||
elif [ -n "$query" ]; then
|
||||
qalc_res="$(qalc --terse "$query")"
|
||||
menu_res="$(echo -e "$qalc_res\ntui" | bemenu --prompt "qalc")"
|
||||
menu_res="$(echo -e "$qalc_res\ntui" | ~/.local/bin/menu/horizontal.sh -p "qalc")"
|
||||
if [ "$qalc_res" = "$menu_res" ]; then
|
||||
wl-copy "$qalc_res"
|
||||
notify-send "$qalc_res" -a calc "Result copied to clipboard"
|
||||
|
||||
Reference in New Issue
Block a user