Mercurial > hg > sonic-visualiser
comparison deploy/clean-build-and-package @ 2395:5d2d3fdae354
Merge
author | Chris Cannam |
---|---|
date | Tue, 22 Oct 2019 16:32:28 +0100 |
parents | ab2d0fe8f0b7 |
children | ab09e05b0d35 |
comparison
equal
deleted
inserted
replaced
2394:32107caa1aaa | 2395:5d2d3fdae354 |
---|---|
1 #!/bin/bash | |
2 | |
3 set -eu | |
4 | |
5 current=$(hg id | awk '{ print $1; }') | |
6 | |
7 #case "$current" in | |
8 # *+) echo "ERROR: Current working copy has been modified - not proceeding"; exit 2;; | |
9 # *);; | |
10 #esac | |
11 | |
12 version=`perl -p -e 's/^[^"]*"([^"]*)".*$/$1/' version.h` | |
13 | |
14 mkdir -p packages | |
15 echo | |
16 | |
17 if [ -d /Applications ]; then | |
18 | |
19 qmake=$(grep '^# Command: ' Makefile | awk '{ print $3; }') | |
20 | |
21 echo "Proceed to rebuild, package, and sign version $version using" | |
22 echo -n "qmake path \"$qmake\" [Yn] ? " | |
23 read yn | |
24 case "$yn" in "") ;; [Yy]) ;; *) exit 3;; esac | |
25 echo "Proceeding" | |
26 | |
27 app="Sonic Visualiser" | |
28 volume="$app"-"$version" | |
29 dmg="$volume".dmg | |
30 | |
31 rm -rf "$app.app" | |
32 rm -f "$dmg" | |
33 | |
34 ./repoint install | |
35 | |
36 rm -rf .qmake.stash | |
37 "$qmake" -r | |
38 make clean | |
39 make -j3 | |
40 deploy/osx/deploy-and-package.sh | |
41 | |
42 mv "$dmg" packages/ | |
43 | |
44 else | |
45 | |
46 echo -n "Proceed to rebuild and package version $version [Yn] ? " | |
47 read yn | |
48 case "$yn" in "") ;; [Yy]) ;; *) exit 3;; esac | |
49 echo "Proceeding" | |
50 | |
51 ./deploy/linux/build-and-test-appimage.sh | |
52 | |
53 squashedversion=$(echo "$version" | sed 's/_-//g') | |
54 | |
55 mv deploy/linux/docker/output/SonicVisualiser-"$current"-x86_64.AppImage \ | |
56 packages/SonicVisualiser-"$squashedversion"-x86_64.AppImage | |
57 | |
58 ./deploy/linux/build-and-test-deb.sh | |
59 | |
60 mv deploy/linux/docker/output/sonic-visualiser_"$version"_amd64.deb \ | |
61 packages/ | |
62 fi | |
63 | |
64 echo "Done" | |
65 |