Fix continue integration in AppVeyor

This commit is contained in:
bao-qian 2015-11-04 03:24:41 +00:00
parent b1eb48d201
commit f2a93887c9
4 changed files with 17 additions and 20 deletions

View File

@ -1,13 +1,7 @@
$root = (split-path -parent $MyInvocation.MyCommand.Definition) + '\..\..'
Write-Host $root
$version = [System.Reflection.Assembly]::LoadFile("$root\Output\Release\Wox.Plugin.dll").GetName().Version
$versionStr = "{0}.{1}.{2}.{3}" -f ($version.Major, $version.Minor, $version.Build, $version.Revision)
$path = $env:APPVEYOR_BUILD_FOLDER + "\Deploy\Nuget\wox.plugin.nuspec"
Write-Host "Setting .nuspec version tag to $versionStr"
$current_path = Convert-Path .
Write-Host "Current path: " + $current_path
Write-Host "Target path: " + $path
$content = (Get-Content $root\Deploy\NuGet\wox.plugin.nuspec)
$content = $content -replace '\$version\$',$versionStr
$content | Out-File $root\deploy\nuget\wox.plugin.nuspec
& $root\.nuget\NuGet.exe pack $root\deploy\nuget\wox.plugin.nuspec
& nuget pack $path -Version $env:APPVEYOR_BUILD_VERSION

View File

@ -1,2 +0,0 @@
cd /d %~dp0
%~dp0Wox.UpdateFeedGenerator.exe

View File

@ -0,0 +1,9 @@
$path = $env:APPVEYOR_BUILD_FOLDER + "\Deploy\UpdateGenerator"
$current_path = Convert-Path .
Write-Host "Current path: " + $current_path
Write-Host "Target path: " + $path
Set-Location $path
& ".\Wox.UpdateFeedGenerator.exe"
Set-Location $current_path

View File

@ -1,23 +1,19 @@
version: 1.2.0.{build}
branches:
only:
- master
os: Visual Studio 2015
configuration: Release
platform: Any CPU
assembly_info:
patch: true
file: AssemblyInfo.*
assembly_version: 1.2.0
assembly_version: '{version}'
assembly_file_version: '{version}'
assembly_informational_version: '{version}-$(APPVEYOR_REPO_COMMIT)'
before_build:
- ps: nuget restore
build:
project: Wox.sln
publish_nuget: true
after_build:
- cmd: .\Deploy\UpdateGenerator\build.bat
- ps: .\Deploy\UpdateGenerator\build.ps1
after_test:
- ps: .\Deploy\Nuget\pack.ps1
artifacts:
@ -33,4 +29,4 @@ deploy:
secure: AMF+zWfGP+02wq2u33PfSyCI2AbD+eek1ljd9q6zs0qEPMP+YwVF5mF9X1+XJD4wPItJB+S8h1AANUowXgfpd29aaYNmS73HWgaL6fqnN2U=
artifact: nugetpackage
on:
branch: master
branch: master