forked from ankitpokhrel/wp-dev
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwpdev
More file actions
executable file
·50 lines (39 loc) · 788 Bytes
/
wpdev
File metadata and controls
executable file
·50 lines (39 loc) · 788 Bytes
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
#!/bin/bash
readonly CMD_PATH="./core/scripts/"
function usage
{
echo "
Usage: wpdev
Build all images and projects by default.
Commands:
up Start all related containers
down Stop all related containers
db Perform database related operations
build [--no-cache] [-h] Build the infra
destroy [--force] [-f] Destroy the infra
rebuild [--no-cache] [-h] Rebuild the infra
"
}
case $1 in
up )
${CMD_PATH}up
;;
down )
${CMD_PATH}down
;;
build )
${CMD_PATH}build "${@:2}"
;;
destroy )
${CMD_PATH}destroy "${@:2}"
;;
rebuild )
${CMD_PATH}rebuild "${@:2}"
;;
db )
${CMD_PATH}db "${@:2}"
;;
* )
usage
;;
esac