-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.sh
58 lines (44 loc) · 1.16 KB
/
app.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
#!bin/sh
# @author efen
# to help with common command-line tasks like generating documentation
# incase of windows `$'\r': command not found` errors run sed -i 's/\r$//' app.sh to resolve it
# take command line command that is passed
action=$1
echo_help() {
echo "-h or help command helps offer help to LifeBoat app users"
echo "You can use any of these commands to interface with the application"
echo ""
echo -e '\t make-docs --> This command helps generate documentation which is stored in docs/'
echo -e "\t -h or help --> This command offers help to users"
echo -e "\t -h or help --> This command offers help to users"
echo -e "\t prepare --> This command installs all the npm libraries the server requires"
echo -e "\t start --> This command starts the server"
echo -e ""
echo -e "\t\t\t\t END"
echo -e ""
echo -e "Author Efen"
}
case $action in
help)
echo_help
;;
-h)
echo_help
echo 'help'
;;
prepare)
npm i
;;
start)
npm start
;;
make-docs)
npm run-script make-docs
;;
test)
npm test
;;
*)
echo_help
;;
esac