new script: choose
This commit is contained in:
parent
d37ff629ab
commit
5b3d57ecae
1 changed files with 11 additions and 0 deletions
11
misc/choose
Executable file
11
misc/choose
Executable file
|
@ -0,0 +1,11 @@
|
||||||
|
#!/bin/zsh
|
||||||
|
|
||||||
|
zparseopts -D -E x=xorg -xorg=xorg
|
||||||
|
|
||||||
|
chosen="${@[RANDOM % $# + 1]}"
|
||||||
|
|
||||||
|
if [[ $xorg ]]; then
|
||||||
|
zenity --info --text=$chosen
|
||||||
|
else
|
||||||
|
echo $chosen
|
||||||
|
fi
|
Loading…
Add table
Add a link
Reference in a new issue