aboutsummaryrefslogtreecommitdiff
path: root/dmenuTerm.sh
blob: a6d459c3237402faf4188bee767e61760c9f543d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/sh
# dmenu script for opening console programs and scripts directly

options="neofetch\ncmus\ncmus (float)\nweather\nReset NetworkManager\nwifiUp\nwifiDown\nyears\nmonths\nwp selection\nshowColors\npython\nmusicMode\nClose music mode\n"

count="$(printf "$options" | wc -l)"

chosen="$(printf "$options" | dmenu -l "$count" -p "~$ urxvt -e")"

case "$chosen" in
	# floating windows
	"neofetch") urxvt -title invisible -sh 100 -cr "#aaddff" -geometry "80x21+50+35" -e ~/scripts/neofetch.sh ;;
	"showColors") urxvt -title floating -sh 10 -cr black -geometry 44x9 -e ~/scripts/showColors.sh ;;
	"years") ~/scripts/floats/floatYears.sh ;;
	"months") ~/scripts/floats/floatMonths.sh ;;
	"weather") urxvt -title floating -sh 10 -geometry 125x40 -e weather.sh ;;
	"wp selection") ~/scripts/floats/floatWpBrowser.sh "$CONFIG_FOLDER_WP" ;;
	"python") urxvt -title floating -geometry 80x28 -e python -q ;;
	#programs
	"cmus") urxvt -cd ~/music -e cmus ;;
	"cmus (float)") urxvt -title floating -sh 20 -geometry "150x12+5-8" -cd ~/music -e cmus ;;
	# sudo stuff
	"Restart NetworkManager") sudo systemctl restart NetworkManager ;;
	"wifiUp") wifiUp.sh ;;
	"wifiDown") wifiDown.sh ;;
	# other
	"musicMode") ~/scripts/musicMode.sh ;;
	"Close music mode") ~/scripts/closeMusicMode.sh  ;;
esac