rice/dots/.scripts/dmenucalc
2021-03-11 00:07:19 +02:00

10 lines
205 B
Bash
Executable file

#!/bin/sh
docalc() {
res=$(true | dmenu -p "calc" | bc)
[ "$res" = "" ] && exit
next=$(printf "exit\nnext" | dmenu -p "calc;res=${res}")
[ "next" = "${next}" ] && docalc || exit
}
docalc