-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmenu.sh
108 lines (49 loc) · 1.35 KB
/
menu.sh
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
#!/bin/bash
function press_enter
{
echo ""
echo -n "Press Enter to continue"
read
clear
}
function today {
echo "Today's date is: "
date +"%A, %B %-d, %Y"
}
selection=
until [ "$selection" = "0" ]; do
clear
echo ""
echo "COMMAND LINE MENU"
echo " ---------------------------"
echo "1 - display free disk space"
echo "2 - display free memory"
echo "3 - display current date"
echo "4 - display processes"
echo "5 - Shut Down SSH Service"
echo "6 - Start Up SSH Service"
echo "7 - other programs"
echo "8 - Phone Numbers"
echo "8.5 - Do not select this!"
echo "9 - Password Database"
echo " ----------------------------"
echo "0 - exit menu"
echo ""
echo -n "Enter selection: "
read selection
echo ""
case $selection in
1 ) df ; press_enter ;;
2 ) free ; press_enter ;;
3 ) today ; press_enter ;;
4 ) ps -ef; press_enter;;
5 ) net stop sshd; press_enter;;
6 ) net start sshd; press_enter;;
7 ) games;;
8 ) utkphonwin ;;
8.5 ) phbook ;;
9 ) COB_PRE_LOAD=cobdes utpasssecwin ;;
0 ) exit ;;
* ) echo "Please enter 1, 2, or 0"; press_enter
esac
done