Skip to content

Commit

Permalink
Merge pull request #300 from erikbra/AppVeyor-gitversion
Browse files Browse the repository at this point in the history
Add GitVersion-config
  • Loading branch information
BiggerNoise committed Nov 12, 2017
2 parents bd238e0 + ef59cc1 commit 133d0d9
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 9 deletions.
8 changes: 8 additions & 0 deletions GitVersion.yml
@@ -0,0 +1,8 @@
assembly-versioning-scheme: None
mode: ContinuousDelivery
branches:
master:
mode: ContinuousDelivery
tag: pre
ignore:
sha: []
22 changes: 15 additions & 7 deletions appveyor.yml
@@ -1,13 +1,21 @@
version: 1.0.{build}
image: Visual Studio 2017

install:
- choco install gitversion.portable -pre -y

before_build:
- ps: gitversion /l console /output buildserver

build_script:
- ps: .\build.ps1
- ps: .\build.ps1

test:
assemblies:
only:
- '**\*tests.dll'
- '**\*tests.dll'

artifacts:
- path: .\code_drop\packages\*.nupkg
name: Nuget packages
- path: .\code_drop\log\*
name: Logs
- path: .\code_drop\packages\*.nupkg
name: Nuget packages
- path: .\code_drop\log\*
name: Logs
4 changes: 2 additions & 2 deletions build.ps1
@@ -1,4 +1,4 @@
#!/usr/bin/env powershell
#!/usr/bin/env pwsh

$MSBUILD=msbuild

Expand All @@ -19,7 +19,7 @@ pushd $root
$gitVersion = (GitVersion | ConvertFrom-Json)

If ($onAppVeyor) {
$newVersion="$($gitVersion.FullSemVer).$env:APPVEYOR_BUILD_NUMBER"
$newVersion="$($gitVersion.FullSemVer)"
Write-host " - Updating appveyor build version to: $newVersion"
$env:APPVEYOR_BUILD_VERSION="$newVersion"
appveyor UpdateBuild -Version "$newVersion"
Expand Down

0 comments on commit 133d0d9

Please sign in to comment.