forked from vinco/wordpress-workflow
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstartProject.sh
More file actions
executable file
·40 lines (32 loc) · 884 Bytes
/
startProject.sh
File metadata and controls
executable file
·40 lines (32 loc) · 884 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
#!/bin/bash
#
# startProject.sh
#
# creates the basic structure needed to develop a new wordpress project
DIR="${BASH_SOURCE%/*}"
if [[ ! -d "$DIR" ]]; then DIR="$PWD"; fi
# create every folder needed
echo "Creando estructura de directorios"
if [[ ! -d "$DIR/../src" ]]; then
mkdir $DIR/../src
fi
if [[ ! -d "$DIR/../src/themes" ]]; then
mkdir $DIR/../src/themes
fi
if [[ ! -d "$DIR/../src/plugins" ]]; then
mkdir $DIR/../src/plugins
fi
if [[ ! -d "$DIR/../src/init" ]]; then
mkdir $DIR/../src/init
fi
if [[ ! -d "$DIR/../src/database" ]]; then
mkdir $DIR/../src/database
fi
echo "Enlaces simbolicos..."
ln -s $DIR/Vagrantfile $DIR/../Vagrantfile
ln -s $DIR/fabfile.py $DIR/../fabfile.py
cp $DIR/defaults/environments.json $DIR/../environments.json
cp $DIR/defaults/settings.json $DIR/../settings.json
echo "Inicia maquina virtual"
cd $DIR/../
vagrant up