-
Notifications
You must be signed in to change notification settings - Fork 28
/
menuopts
81 lines (71 loc) · 2.11 KB
/
menuopts
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
#!/bin/bash
# KD4Z
# Version: 4.53
# main menu
vers="4.53"
if [ ! -f /etc/motd.save ]; then
. ~/md380tools-vm/root/.bash_aliases
fi
. ~/md380tools-vm/strings
countmarc=$(wc --lines ~/user.bin | cut -d" " -f1)
userbinsize=$(ls -l ~/user.bin | cut -d" " -f5)
clear
if (( countmarc < 80000 )); then
cntcolor=${RED}
else
cntcolor=${GREEN}
fi
echo -e " ${WHITE}${ZPROJ} (v${vers})${NC}\t (${ZCOUNT1}${cntcolor} ${countmarc} / ${userbinsize}${NC} bytes)"
echo -e ""
echo -e " ${ZMESS11}"
echo -e " ${ZMESS12}"
#if [ -f /etc/motd.save ]; then
# echo -e " ${ZMESS13}"
# echo -e " ${ZMESS14}"
#fi
echo -e ""
echo -e " ${ZMESS15}"
if [ -f /etc/motd.save ]; then
echo -e " ${ZMESS16}"
#echo -e " ${ZMESS17}"
fi
echo -e ""
echo -e -n " ${YELLOW}${ZCOM1}${NC} -- (${YELLOW}G${NC}et ${YELLOW}L${NC}atest ${YELLOW}V${NC}ersion) ${ZCOM11}"
if [ -f ~/md380tools-vm/glv.mike ]; then
echo -e -n " ${RED}(Mike)"
fi
if [ -f ~/md380tools-vm/glv.wolf ]; then
echo -e -n " ${RED}(Wolf)"
fi
echo -e "${NC}"
echo -e " ${YELLOW}${ZCOM10}${NC} -- ${ZCOM12}"
echo -e ""
echo -e " ${ZSEL4}"
echo -e ""
if [ ! -f ~/firmware-noGPS.bin ]; then
echo -e " ${YELLOW}${ZCOM2}${NC} -- ${RED} Not available. Run ${YELLOW}glv ${RED}again${NC}"
else
echo -e " ${YELLOW}${ZCOM2}${NC} -- ${RED}(DFU)${NC} ${ZWRITE1} (${ZRAD10})"
fi
if [ ! -f ~/firmware-GPS.bin ]; then
echo -e " ${YELLOW}${ZCOM3}${NC} -- ${RED} Not available. Run ${YELLOW}glv ${RED}again${NC}"
else
echo -e " ${YELLOW}${ZCOM3}${NC} -- ${RED}(DFU)${NC} ${ZWRITE2} (${ZRAD20})"
fi
if [ ! -f ~/user.bin ]; then
echo -e " ${YELLOW}${ZCOM4}${NC} -- ${RED} Not available. Run ${YELLOW}glv ${RED}or ${YELLOW}glvusers ${RED}again{NC}"
else
echo -e " ${YELLOW}${ZCOM4}${NC} -- ${RED}(${ZCOM24}) ${NC} ${ZWRITE3}"
fi
echo -e ""
echo -e " ${YELLOW}${ZCOM5}${NC} ${BLUE}${ZCOM51}${NC} -- ${ZWRITE4} "
echo -e ""
echo -e -n "\t${YELLOW}menu${NC} -- ${ZMESS61}${NC}"
if [ -f /etc/motd.save ]; then
echo -e " (${ZCOM20} ${WHITE}Ctrl+D${NC})"
else
echo -e ""
fi
echo -e "\t${YELLOW}${ZCOM8}${NC} -- ${ZCOM22}"
echo -e "\t${YELLOW}help${NC} -- ${ZMESS71}"
echo -e ""