-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathshuttle.sh
executable file
·92 lines (86 loc) · 1.15 KB
/
shuttle.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
#!/bin/bash
. ./sh/init.sh
# sets the position
function position() {
pos="0"
while [[ $pos == "0" ]]; do
input "$posnum" position
case $position in
"-001" | "POS001" )
pos="CMDR"
;;
"-002" | "POS002" )
pos="PLT"
;;
"-003" | "POS003" )
pos="FD"
;;
"-004" | "POS004" )
pos="WXT"
;;
"-005" | "POS005" )
pos="LD"
;;
"-006" | "POS006" )
pos="ELSS"
;;
"-007" | "POS007" )
pos="SSO"
;;
"-008" | "POS008" )
pos="PAO"
;;
"+" | "HELP" )
echo -e "$posinfo"
;;
* )
echo -e "$nopos"
;;
esac
if [[ $pos != 0 ]]; then
echo -e "$posis ${green}$pos${NC}"
fi
done
}
. ./sh/util.sh
. ./sh/pos/CMDR.sh
. ./sh/pos/PLT.sh
. ./sh/pos/FD.sh
. ./sh/pos/WXT.sh
. ./sh/pos/LD.sh
. ./sh/pos/ELSS.sh
. ./sh/pos/SSO.sh
. ./sh/pos/PAO.sh
# main method
while [[ true ]]; do
position
while [[ $exiting != true ]]; do
case $pos in
"CMDR" )
CMDR
;;
"PLT" )
PLT
;;
"FD" )
FD
;;
"WXT" )
WXT
;;
"LD" )
LD
;;
"ELSS" )
ELSS
;;
"SSO" )
SSO
;;
"PAO" )
PAO
;;
esac
done
exiting=false
done