aboutsummaryrefslogtreecommitdiffhomepage
path: root/scripts/release.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/release.sh')
-rwxr-xr-xscripts/release.sh30
1 files changed, 28 insertions, 2 deletions
diff --git a/scripts/release.sh b/scripts/release.sh
index 572e6bdca..07fec00b8 100755
--- a/scripts/release.sh
+++ b/scripts/release.sh
@@ -1,7 +1,33 @@
1#!/bin/bash 1#!/bin/bash
2 2
3npm run build 3shutdown() {
4npm test 4 # Get our process group id
5 PGID=$(ps -o pgid= $$ | grep -o [0-9]*)
6
7 # Kill it in a new new process group
8 setsid kill -- -$PGID
9 exit 0
10}
11
12trap "shutdown" SIGINT SIGTERM
13
14if [ -z "$1" ]; then
15 echo "Need version as argument"
16 exit -1
17fi
18
19cd ./client || exit -1
20npm version --no-git-tag-version --no-commit-hooks $1 || exit -1
21
22cd ../ || exit -1
23npm version -f --no-git-tag-version --no-commit-hooks $1 || exit -1
24
25git commit package.json client/package.json -m "Bumped to version $1" || exit -1
26git tag -s -a "v$1" -m "v$1"
27
28npm run build || exit -1
29#npm test || exit -1
5 30
6cd ../ || exit -1 31cd ../ || exit -1
32rm -f PeerTube/peertube.zip || exit -1
7zip -r PeerTube/peertube.zip PeerTube/{CREDITS.md,node_modules,FAQ.md,LICENSE,README.md,client/dist/,client/yarn.lock,client/package.json,config,dist,package.json,scripts,support,tsconfig.json,yarn.lock} 33zip -r PeerTube/peertube.zip PeerTube/{CREDITS.md,node_modules,FAQ.md,LICENSE,README.md,client/dist/,client/yarn.lock,client/package.json,config,dist,package.json,scripts,support,tsconfig.json,yarn.lock}