Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
127 lines (102 sloc) 5.04 KB
version: '{build}'
init:
- ps: |
If ($Env:APPVEYOR_REPO_TAG_NAME -match "-"){
Set-AppveyorBuildVariable -Name "IsPreRelease" -Value True
}
Else{
Set-AppveyorBuildVariable -Name "IsPreRelease" -Value False
}
before_build:
- ps: |
# Enables RDP for debugging
# $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
$ver = "0.0.0";
If( Test-Path Env:APPVEYOR_REPO_TAG_NAME ){
$ver = $Env:APPVEYOR_REPO_TAG_NAME.Substring(1)
}
$major = $ver.Split(".")[0]
$minor = $ver.Split(".")[1]
$rev = $ver.Split(".")[2]
$buildnum = $Env:APPVEYOR_BUILD_VERSION
# ###################
# SET VERSION HEADERS
# ###################
$versionInfo = @'
// This is the main version file.
// If you are building locally, you can modify these values.
// If you are building though appveyor (or GitHub releases),
// change the version in appveyor.yml. The CI build process
// will overwrite these values.
#pragma once
#define VERSION_MAJOR >major
#define VERSION_MINOR >minor
#define REVISION_NUMBER >rev
#define BUILD_NUMBER >buildnum
'@
$versionInfo = $versionInfo -replace ">buildnum",$buildnum
$versionInfo = $versionInfo -replace ">rev",$rev
$versionInfo = $versionInfo -replace ">major",$major
$versionInfo = $versionInfo -replace ">minor",$minor
$versionInfo | out-file -FilePath source/Client/VersionInfo.h
build_script: build.cmd
test: off
# assemblies:
# - Unit.Tests.dll
after_build:
- ps: cd __package\; 7z a BugTrap.zip **
# Zip relative to __package directory
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrapD.dll
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrapD.lib
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrap.dll
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrap.lib
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapUD.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapUD.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapU.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapU.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapDN.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapDN.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapN.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapN.lib"
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrapD-x64.dll
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrapD-x64.lib
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrap-x64.dll
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\bin\BugTrap-x64.lib
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapUD-x64.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapUD-x64.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapU-x64.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapU-x64.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapDN-x64.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapDN-x64.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapN-x64.dll"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\BugTrapN-x64.lib"
- 7z a BugTrap.zip "%APPVEYOR_BUILD_FOLDER%\bin\CrashExplorer.exe"
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\source\Client\BTAtlWindow.h
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\source\Client\BTMfcWindow.h
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\source\Client\BTTrace.h
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\source\Client\BugTrap.h
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\doc\BugTrap.pdf
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\doc\ReadMe.txt
- 7z a BugTrap.zip %APPVEYOR_BUILD_FOLDER%\pkg\dbghelp.dll
artifacts:
- path: __package\BugTrap.zip
name: Zip
nuget:
disable_publish_on_pr: true
deploy:
- provider: GitHub
release: 'Release $(APPVEYOR_REPO_TAG_NAME) build $(APPVEYOR_BUILD_VERSION)'
tag: $(APPVEYOR_REPO_TAG_NAME)
description: '[**CHANGE LOG**](https://github.com/bchavez/BugTrap/blob/master/HISTORY.md)'
prerelease: $(IsPreRelease)
artifact: Zip
auth_token:
secure: cyivrWQwrZNAb6UCNXlIQlGfVSnKIC6TatUOIP95CQgMeKGnmBSqBgAFv2TsRZhR
on:
branch: master
appveyor_repo_tag_name: /v\d+\.\d+\.\d+/
appveyor_repo_tag: true
on_failure:
- ps: |
# Enables RDP for debugging and setup some tools
# $blockRdp = $true; choco install notepad2; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
You can’t perform that action at this time.