-
Notifications
You must be signed in to change notification settings - Fork 35
/
release.sh
executable file
·51 lines (46 loc) · 1.2 KB
/
release.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
43
44
45
46
47
48
49
50
51
# on Windows it requires Cygwin or MSYS
case ${OSTYPE} in
msys|cygwin )
versinfo=versinfo.exe
FreeShip=FreeShip.exe
INST_SCRIPTS="uninstall-user.cmd install-user.cmd"
MISCFILES="*.dll"
ARCH=$(file -b ${FreeShip}|cut -f4 -d' '|sed 's/,//')
OS=windows;;
linux-gnu )
versinfo=versinfo
FreeShip=FreeShip
INST_SCRIPTS="install-system.sh uninstall-system.sh uninstall-user.sh install-user.sh"
MISCFILES=""
ARCH=$(file -b ${FreeShip}|cut -f5 -d' '|sed 's/,//')
OS=linux;;
esac
# Zips files for binary distribution
#BLDDT=$(strings ${FreeShip} |grep Build:|cut -f2 -d' ')
VERS=$(Utils/versinfo --FileFullVersion --NoVerbose ${FreeShip}|tr -d '\r'|tr -d '\n')
echo "VERS: $VERS"
if [ -x /usr/bin/git ]
then
git tag -a v$VERS -m "Test Release. $ARCH $OS Qt. ver $VERS"
fi
if [ $OS = linux ]; then
cd instpkg/zip
./zipbin.sh
cd -
fi
if [ $OS = windows ]; then
cd instpkg/wix/
cmd.exe /C make_installer.cmd
cd -
mv instpkg/wix/FreeShip_x64.msi Releases/"FreeShip-${VERS}_x64.msi"
fi
# if we have tools for .deb creation
if [ -x /usr/bin/lintian ] ; then
echo
echo Create deb package
cd instpkg/deb/
./prep.sh
./build.sh
cd -
mv instpkg/deb/freeship_*.deb Releases/
fi