mirror of
https://github.com/greenshot/greenshot
synced 2025-08-19 21:13:23 -07:00
Changed build to generate UNSTABLE files when the build in major.minor.build.revision is odd. Currently we are building 1.2.0 which will result in an unstable. When we change the version to 1.2.1 in AppVeyor we get releases.
This commit is contained in:
parent
f1642f3014
commit
9bed298611
4 changed files with 20 additions and 10 deletions
|
@ -5,7 +5,7 @@ Apply text and shapes to the screenshot. Offers capture of window, region or ful
|
||||||
|
|
||||||
CHANGE LOG:
|
CHANGE LOG:
|
||||||
|
|
||||||
@DETAILVERSION@ UNSTABLE
|
@DETAILVERSION@
|
||||||
|
|
||||||
Features:
|
Features:
|
||||||
* Feature #184,#282,#486: Image editor now has a Speech bubble
|
* Feature #184,#282,#486: Image editor now has a Speech bubble
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[Format]
|
[Format]
|
||||||
Type=PortableApps.comFormat
|
Type=PortableApps.comFormat
|
||||||
Version=@VERSION@
|
Version=2.0
|
||||||
|
|
||||||
[Details]
|
[Details]
|
||||||
Name=Greenshot Portable
|
Name=Greenshot Portable
|
||||||
|
@ -22,14 +22,14 @@ EULAVersion=true
|
||||||
|
|
||||||
[Version]
|
[Version]
|
||||||
PackageVersion=@DETAILVERSION@
|
PackageVersion=@DETAILVERSION@
|
||||||
DisplayVersion=@VERSION@
|
DisplayVersion=@FILEVERSION@
|
||||||
|
|
||||||
[SpecialPaths]
|
[SpecialPaths]
|
||||||
Plugins=NONE
|
Plugins=NONE
|
||||||
|
|
||||||
[Dependencies]
|
[Dependencies]
|
||||||
UsesJava=false
|
UsesJava=false
|
||||||
UsesDotNetVersion=4.5
|
UsesDotNetVersion=3.5
|
||||||
|
|
||||||
[Control]
|
[Control]
|
||||||
Icons=1
|
Icons=1
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#define ExeName "Greenshot"
|
#define ExeName "Greenshot"
|
||||||
#define Version "@VERSION@"
|
#define Version "@VERSION@"
|
||||||
#define DetailVersion "@DETAILVERSION@"
|
#define FileVersion "@FILEVERSION@"
|
||||||
|
|
||||||
; Include the scripts to install .NET Framework
|
; Include the scripts to install .NET Framework
|
||||||
; See http://www.codeproject.com/KB/install/dotnetfx_innosetup_instal.aspx
|
; See http://www.codeproject.com/KB/install/dotnetfx_innosetup_instal.aspx
|
||||||
|
@ -122,7 +122,7 @@ InfoBeforeFile=..\additional_files\readme.txt
|
||||||
LicenseFile=..\additional_files\license.txt
|
LicenseFile=..\additional_files\license.txt
|
||||||
LanguageDetectionMethod=uilanguage
|
LanguageDetectionMethod=uilanguage
|
||||||
MinVersion=0,5.01.2600
|
MinVersion=0,5.01.2600
|
||||||
OutputBaseFilename={#ExeName}-INSTALLER-{#Version}
|
OutputBaseFilename={#ExeName}-INSTALLER-{#FileVersion}
|
||||||
OutputDir=..\
|
OutputDir=..\
|
||||||
PrivilegesRequired=none
|
PrivilegesRequired=none
|
||||||
SetupIconFile=..\..\icons\applicationIcon\icon.ico
|
SetupIconFile=..\..\icons\applicationIcon\icon.ico
|
||||||
|
|
18
build.ps1
18
build.ps1
|
@ -24,7 +24,17 @@
|
||||||
|
|
||||||
$version=$env:APPVEYOR_BUILD_VERSION
|
$version=$env:APPVEYOR_BUILD_VERSION
|
||||||
$gitcommit=$env:APPVEYOR_REPO_COMMIT
|
$gitcommit=$env:APPVEYOR_REPO_COMMIT
|
||||||
|
$gitcommit=$gitcommit.SubString(0, [math]::Min($gitcommit.Length, 6))
|
||||||
$detailversion=$version + '-' + $gitcommit
|
$detailversion=$version + '-' + $gitcommit
|
||||||
|
$release=(([version]$version).build) % 2 -eq 1
|
||||||
|
$fileversion=$version
|
||||||
|
# Add the UNSTABLE, if we aren't a release -> the build is even. (major.minor.build.revision)
|
||||||
|
if ( ! $release) {
|
||||||
|
$fileversion=$version + "-UNSTABLE"
|
||||||
|
$detailversion=$detailversion + " UNSTABLE"
|
||||||
|
} else {
|
||||||
|
$detailversion=$detailversion + " Release"
|
||||||
|
}
|
||||||
Write-Host "Building Greenshot $detailversion"
|
Write-Host "Building Greenshot $detailversion"
|
||||||
|
|
||||||
# Create a MD5 string for the supplied filename
|
# Create a MD5 string for the supplied filename
|
||||||
|
@ -49,7 +59,7 @@ Function FillTemplates {
|
||||||
# Create an empty array, this will contain the replaced lines
|
# Create an empty array, this will contain the replaced lines
|
||||||
$newtext = @()
|
$newtext = @()
|
||||||
foreach ($line in $template) {
|
foreach ($line in $template) {
|
||||||
$newtext += $line -replace "\@VERSION\@", $version -replace "\@DETAILVERSION\@", $detailversion
|
$newtext += $line -replace "\@VERSION\@", $version -replace "\@DETAILVERSION\@", $detailversion -replace "\@FILEVERSION\@", $fileversion
|
||||||
}
|
}
|
||||||
# Write the new information to the file
|
# Write the new information to the file
|
||||||
$newtext | Set-Content $newfile -encoding UTF8
|
$newtext | Set-Content $newfile -encoding UTF8
|
||||||
|
@ -132,8 +142,8 @@ Function PackageZip {
|
||||||
$destinstaller = "$destbase\NO-INSTALLER"
|
$destinstaller = "$destbase\NO-INSTALLER"
|
||||||
|
|
||||||
# Only remove the zip we are going to create, to prevent adding but keeping the history
|
# Only remove the zip we are going to create, to prevent adding but keeping the history
|
||||||
if (Test-Path ("$destbase\Greenshot-NO-INSTALLER-$version.zip")) {
|
if (Test-Path ("$destbase\Greenshot-NO-INSTALLER-$fileversion.zip")) {
|
||||||
Remove-Item "$destbase\Greenshot-NO-INSTALLER-$version.zip" -Confirm:$false
|
Remove-Item "$destbase\Greenshot-NO-INSTALLER-$fileversion.zip" -Confirm:$false
|
||||||
}
|
}
|
||||||
# Remove the directory to create the files in
|
# Remove the directory to create the files in
|
||||||
if (Test-Path ("$destinstaller")) {
|
if (Test-Path ("$destinstaller")) {
|
||||||
|
@ -170,7 +180,7 @@ Function PackageZip {
|
||||||
|
|
||||||
$zipOutput = "$(get-location)\zip"
|
$zipOutput = "$(get-location)\zip"
|
||||||
$zip7 = "$(get-location)\greenshot\tools\7zip\7za.exe"
|
$zip7 = "$(get-location)\greenshot\tools\7zip\7za.exe"
|
||||||
$arguments = @('a', '-mx9', '-tzip', '-r', "$destbase\Greenshot-NO-INSTALLER-$version.zip", "$destinstaller\*")
|
$arguments = @('a', '-mx9', '-tzip', '-r', "$destbase\Greenshot-NO-INSTALLER-$fileversion.zip", "$destinstaller\*")
|
||||||
Write-Host "Starting $zip7 $arguments"
|
Write-Host "Starting $zip7 $arguments"
|
||||||
$zipResult = Start-Process -wait -PassThru "$zip7" -ArgumentList $arguments -NoNewWindow -RedirectStandardOutput "$zipOutput.log" -RedirectStandardError "$zipOutput.error"
|
$zipResult = Start-Process -wait -PassThru "$zip7" -ArgumentList $arguments -NoNewWindow -RedirectStandardOutput "$zipOutput.log" -RedirectStandardError "$zipOutput.error"
|
||||||
Write-Host "Log output:"
|
Write-Host "Log output:"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue