-
Notifications
You must be signed in to change notification settings - Fork 20
/
deploy.sh
executable file
·43 lines (36 loc) · 897 Bytes
/
deploy.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
#!/bin/bash
#
# Simple deployment script. Can create a zip file from all
# files or can copy to a Joomla! folder (to update an
# existing installation)
#
# set to the joomla directory you want to deploy to:
dstdir=
# internal variables to be updated when files are added:
extname=bfstop
sqlfiles="sql"
srcfiles="$extname.php helpers $extname.xml $sqlfiles updatescript.php index.html"
langfiles="language"
docs="CHANGELOG LICENSE.txt README"
plgtype="system"
langs="de-DE en-GB"
version=1.5.2
if [ "$1" == "zip" ]
then
zip -r $extname-$version.zip $srcfiles $docs $langfiles
exit
fi
if [ "$1" != "" ]
then
dstdir=$1
fi
if [ "$dstdir" == "" ]
then
echo "You have to set dstdir variable first (to the joomla directory you want to deploy to)"
exit
fi
cp -r $srcfiles $dstdir/plugins/$plgtype/$extname/
for lang in $langs
do
cp language/$lang/* $dstdir/administrator/language/$lang/
done