Skip to content

Commit 5de08e1

Browse files
committed
Merge pull request #62 from Pilchie/nuget-versioning
Use the appveyor version for the nupkg if present.
2 parents fcff523 + c7c33af commit 5de08e1

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

xunit.runner.wpf/xunit.runner.wpf.csproj

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
<NuGetPackageImportStamp>
1818
</NuGetPackageImportStamp>
1919
<TargetFrameworkProfile />
20+
<NuPkgVersion Condition="'$(appveyor_build_version)' != ''">$(appveyor_build_version)</NuPkgVersion>
21+
<NuPkgVersion Condition="'$(NuPkgVersion)' == ''">1.0.0-local</NuPkgVersion>
2022
</PropertyGroup>
2123
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
2224
<PlatformTarget>AnyCPU</PlatformTarget>
@@ -192,8 +194,8 @@
192194
</ItemGroup>
193195
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
194196
<Target Name="AfterBuild">
195-
<Exec Command="&quot;$(SolutionDir)packages\NuGet.CommandLine.3.4.3\tools\NuGet.exe&quot; pack xunit.runner.wpf.nuspec -NoPackageAnalysis -OutputDirectory ." WorkingDirectory="$(OutDir)" LogStandardErrorAsError="true" ConsoleToMSBuild="true">
197+
<Exec Command="&quot;$(SolutionDir)packages\NuGet.CommandLine.3.4.3\tools\NuGet.exe&quot; pack xunit.runner.wpf.nuspec -Version $(NuPkgVersion) -OutputDirectory ." WorkingDirectory="$(OutDir)" LogStandardErrorAsError="true" ConsoleToMSBuild="true">
196198
<Output TaskParameter="ConsoleOutput" PropertyName="OutputOfExec" />
197199
</Exec>
198200
</Target>
199-
</Project>
201+
</Project>

xunit.runner.wpf/xunit.runner.wpf.nuspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<package >
33
<metadata>
44
<id>xunit.runner.wpf</id>
5-
<version>1.0.0</version>
5+
<version>$version$</version>
66
<title>xUnit.Runner.WPF</title>
77
<authors>Pilchie</authors>
88
<owners>Pilchie</owners>
@@ -16,4 +16,4 @@
1616
<file src="*.exe" target="tools\" exclude="*vshost*"/>
1717
<file src="*.config" target="tools\" exclude="*vshost*"/>
1818
</files>
19-
</package>
19+
</package>

0 commit comments

Comments
 (0)