Fix installation for windows
This commit is contained in:
@@ -17,7 +17,7 @@ env:
|
||||
# Environment variables for packaging
|
||||
- PRODUCT=flameshot
|
||||
#TODO: we should take version from the last tag in git history + build number
|
||||
- VERSION=0.7.30.7.3
|
||||
- VERSION=0.7.3
|
||||
- RELEASE=1
|
||||
- ARCH=x86_64
|
||||
# Dockerfile from https://github.com/flameshotapp/flameshot-docker-images
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
image: Visual Studio 2015
|
||||
|
||||
#TODO: we should take version from the last tag in git history + build number
|
||||
version: 0.7.30.7.3.{build}
|
||||
version: 0.7.3.{build}
|
||||
# Major_Version_Number.Minor_Version_Number.Patch_Number.Build_Number
|
||||
|
||||
skip_branch_with_pr: true
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
win32:LIBS += -luser32 -lshell32
|
||||
|
||||
BASE_VERSION = 0.7.30.7.3
|
||||
BASE_VERSION = 0.7.3
|
||||
TAG_VERSION = "$$system(git --git-dir $$PWD/.git rev-parse --short HEAD)"
|
||||
isEmpty(TAG_VERSION){
|
||||
DEFINES += APP_VERSION=\\\"$$BASE_VERSION\\\"
|
||||
|
||||
@@ -1,18 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
BASE_VERSION_NEW="0.7.3"
|
||||
BASE_VERSION_CUR=$(cat flameshot.pro |grep "[0-9]\+\.[0-9]\+\.[0-9]\+" |awk "{print \$3}")
|
||||
|
||||
BASE_VERSION_CUR_EXT=$(cat flameshot.pro |grep "[0-9]\+\.[0-9]\+\.[0-9]\+-[0-9a-e]*" |awk "{print \$3}")
|
||||
BASE_VERSION_CUR=$(echo "${BASE_VERSION_CUR_EXT}" |cut -d '-' -f1)
|
||||
BASE_VERSION_NEW_EXT="${BASE_VERSION_NEW}-$(git rev-parse --short HEAD)"
|
||||
|
||||
if [ "${BASE_VERSION_CUR_EXT}" == "${BASE_VERSION_NEW_EXT}" ]; then
|
||||
if [ "${BASE_VERSION_CUR}" == "${BASE_VERSION_NEW}" ]; then
|
||||
echo "Current and new versions are the same, no action required"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
TAG_EXISTS=$(git ls-remote --tags origin |grep "refs/tags/v${BASE_VERSION_NEW_EXT}")
|
||||
TAG_EXISTS=$(git ls-remote --tags origin |grep "refs/tags/v${BASE_VERSION_NEW}")
|
||||
if [ "" != "${TAG_EXISTS}" ]; then
|
||||
echo "Tag already exists: ${TAG_EXISTS}"
|
||||
echo "Please update to another version or remove git tag"
|
||||
@@ -21,10 +18,14 @@ fi
|
||||
|
||||
# update version to a new one
|
||||
sed -i "s/BASE_VERSION = ${BASE_VERSION_CUR}/BASE_VERSION = ${BASE_VERSION_NEW}/g" flameshot.pro
|
||||
sed -i "s/AppVersion=${BASE_VERSION_CUR_EXT}/AppVersion=${BASE_VERSION_NEW_EXT}/g" ./win_setup/flameshot.iss
|
||||
sed -i "s/VersionInfoVersion=${BASE_VERSION_CUR}/VersionInfoVersion=${BASE_VERSION_NEW}/g" ./win_setup/flameshot.iss
|
||||
sed -i "s/version: ${BASE_VERSION_CUR}/version: ${BASE_VERSION_NEW}/g" appveyor.yml
|
||||
sed -i "s/VERSION=${BASE_VERSION_CUR}/VERSION=${BASE_VERSION_NEW}/g" .travis.yml
|
||||
sed -i "s/VersionInfoVersion=${BASE_VERSION_CUR}/VersionInfoVersion=${BASE_VERSION_NEW}/g" ./win_setup/flameshot.iss
|
||||
|
||||
BASE_VERSION_NEW_EXT="${BASE_VERSION_NEW}-$(git rev-parse --short=7 HEAD)"
|
||||
BASE_VERSION_CUR_EXT=$(cat ./win_setup/flameshot.iss |grep "AppVersion=[0-9]\+\.[0-9]\+\.[0-9]\+-*[0-9a-f]*" |cut -d "=" -f2)
|
||||
echo "BASE_VERSION_CUR_EXT: ${BASE_VERSION_CUR_EXT}"
|
||||
sed -i "s/AppVersion=${BASE_VERSION_CUR_EXT}/AppVersion=${BASE_VERSION_NEW_EXT}/g" ./win_setup/flameshot.iss
|
||||
|
||||
qmake
|
||||
|
||||
|
||||
@@ -6,9 +6,9 @@
|
||||
|
||||
[Setup]
|
||||
AppName=Flameshot
|
||||
AppVersion=0.7.3-a9a41930.7.3
|
||||
AppVersion=0.7.3-3fbd469
|
||||
AppCopyright=NameCheap inc.
|
||||
VersionInfoVersion=0.7.30.7.3
|
||||
VersionInfoVersion=0.7.3
|
||||
WizardStyle=modern
|
||||
DefaultDirName={autopf}\Flameshot
|
||||
DefaultGroupName=Flameshot
|
||||
|
||||
Reference in New Issue
Block a user