Skip to content

Commit

Permalink
Use "choco pack" with custom metadata
Browse files Browse the repository at this point in the history
Now that the change for chocolatey/choco#1313 has been released in
version 0.10.8 use "choco pack" to add custom metadata for
chocolatey.org.
  • Loading branch information
heaths committed Sep 6, 2017
1 parent 2d3a056 commit 03a4081
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 9 deletions.
1 change: 1 addition & 0 deletions .nuget/packages.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="chocolatey" version="0.10.8" />
<package id="vswhere" version="1.0.62" />
</packages>
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ build:
parallel: true

after_build:
- nuget pack -OutputDirectory "bin\%CONFIGURATION%" -Version "%GitBuildVersionSimple%" -Properties "Configuration=%CONFIGURATION%;CommitId=%APPVEYOR_REPO_COMMIT%" pkg\vswhere\vswhere.nuspec
- tools\choco.cmd pack pkg\vswhere\vswhere.nuspec --out "bin\%CONFIGURATION%" --version "%GitBuildVersionSimple%" "Configuration=%CONFIGURATION%" "CommitId=%APPVEYOR_REPO_COMMIT%"

test_script:
- tools\test.cmd -v
Expand Down
4 changes: 0 additions & 4 deletions pkg/vswhere/packages.config

This file was deleted.

9 changes: 5 additions & 4 deletions pkg/vswhere/vswhere.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@
<copyright>Copyright (C) Microsoft Corporation. All rights reserved.</copyright>
<tags>vs vs2017 visualstudio</tags>
<developmentDependency>true</developmentDependency>
<!--packageSourceUrl>https://github.com/Microsoft/vswhere/tree/$CommitId$/pkg/vswhere</packageSourceUrl-->
<!--docsUrl>https://github.com/Microsoft/vswhere/wiki</docsUrl-->
<!--bugTrackerUrl>https://github.com/Microsoft/vswhere/issues</bugTrackerUrl-->
<!--projectSourceUrl>https://github.com/Microsoft/vswhere/tree/$CommitId$</projectSourceUrl-->
<projectSourceUrl>https://github.com/Microsoft/vswhere/tree/$CommitId$</projectSourceUrl>
<packageSourceUrl>https://github.com/Microsoft/vswhere/tree/$CommitId$/pkg/vswhere</packageSourceUrl>
<docsUrl>https://github.com/Microsoft/vswhere/wiki</docsUrl>
<bugTrackerUrl>https://github.com/Microsoft/vswhere/issues</bugTrackerUrl>
<releaseNotes>https://github.com/Microsoft/vswhere/releases/tag/$Version$</releaseNotes>
</metadata>
<files>
<file src="build\vswhere.props" target="build\"/>
Expand Down
9 changes: 9 additions & 0 deletions tools/choco.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
@if not defined _echo echo off
setlocal enabledelayedexpansion

for /d %%i in ("%~dp0..\packages\chocolatey*") do (
for /f "usebackq delims=" %%j in (`where /r "%%i" choco.exe 2^>nul`) do (
"%%j" %*
exit /b !errorlevel!
)
)

0 comments on commit 03a4081

Please sign in to comment.