Auto publish Wox.Plugin to nuget.

This commit is contained in:
qianlifeng
2014-12-12 18:22:17 +08:00
parent b6d01133c4
commit cb9bc6ad12
4 changed files with 48 additions and 0 deletions

12
Deploy/Nuget/pack.ps1 Normal file
View File

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