-
Notifications
You must be signed in to change notification settings - Fork 0
/
one
executable file
·34 lines (25 loc) · 967 Bytes
/
one
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
#!/bin/bash
print_color () { tput setab 7; tput setaf 0; echo "$1"; tput sgr0; }
# Check all required CLIs are available
dependencies=( wget git unzip )
for dependency in "${dependencies[@]}"; do
command -v $dependency >/dev/null 2>&1 || { echo >&2 "‘$dependency’ command is required but it’s not installed. Aborting."; exit 1; }
done
__DIRNAME="hgnm-wp-dev"
WP_DIR="app/public"
######################
# THEME INSTALLATION #
######################
# Set remote URL
THEME_REMOTE_URL="https://github.com/HGNM/hgnm-2014.git"
THEME_LOCAL_DIR="$WP_DIR/wp-content/themes/hgnm-2014"
# Install & activate hgnm-2014 theme
print_color "Cloning hgnm-2014 WordPress theme..."
git clone $THEME_REMOTE_URL $THEME_LOCAL_DIR
#########################
# COPY SCRIPT TWO TO VM #
#########################
cp $__DIRNAME/two app/two
cp $__DIRNAME/hgnm-export.xml app/hgnm-export.xml
print_color "Step 1 finished."
echo "Return to Local, open site SSH, and run ./app/two"