File tree 1 file changed +38
-1
lines changed
1 file changed +38
-1
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,17 @@ prepareChromeFunction()
23
23
sed -i -e ' 28,32d;19d;35d' ./dev/manifest.json
24
24
}
25
25
26
+ packageChromeFunction ()
27
+ {
28
+ prepareChromeFunction
29
+ echo " Creating archive for Chrome"
30
+ cd ./dev/
31
+ zip -qr chrome.zip ./*
32
+ cd ..
33
+ cp ./dev/chrome.zip ./build/
34
+ echo " Archive created in ./build/"
35
+ }
36
+
26
37
prepareFirefoxFunction ()
27
38
{
28
39
echo " Preparing manifest.json for Firefox"
@@ -33,13 +44,27 @@ prepareFirefoxFunction()
33
44
echo " Package for Firefox in ./dev/ created."
34
45
}
35
46
47
+ packageFirefoxFunction ()
48
+ {
49
+ prepareFirefoxFunction
50
+ echo " Creating archive for Firefox"
51
+ cp ./dev/firefox.zip ./build/
52
+ }
53
+
36
54
prepareOperaFunction ()
37
55
{
38
56
echo " Preparing manifest.json for Opera"
39
57
echo " Right now it is the same as Chrome, going for it..."
40
58
prepareChromeFunction
41
59
}
42
60
61
+ packageOperaFunction ()
62
+ {
63
+ prepareOperaFunction
64
+ cp -rf ./dev/* ./build/
65
+ echo " Use Opera and select the ./build/ directory and create a signed package."
66
+ }
67
+
43
68
if [ -z " $1 " ] || ([ " $1 " != " dev" ] && [ " $1 " != " package" ])
44
69
then
45
70
echo " "
70
95
if [ " $1 " == " package" ]
71
96
then
72
97
mkdir -p ./build/
73
- echo " To be developed...."
98
+ rm -rf ./build/*
99
+ echo " Building package for $2 "
100
+ copyDevFunction
101
+ if [ " $2 " == " chrome" ]
102
+ then
103
+ packageChromeFunction
104
+ elif [ " $2 " == " opera" ]
105
+ then
106
+ packageOperaFunction
107
+ else
108
+ packageFirefoxFunction
109
+ fi
110
+ echo " Done, now publish package."
74
111
fi
75
112
76
113
exit 0
You can’t perform that action at this time.
0 commit comments