File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,7 @@ build_script:
24
24
- cmd : 7z a "GitVersion_%GitVersion_NuGetVersion%.zip" .\build\NuGetCommandLineBuild\Tools\*.*
25
25
- cmd : appveyor PushArtifact "GitVersion_%GitVersion_NuGetVersion%.zip"
26
26
27
+ - ps : .\build\Update-GitVersionVsoTaskVersion.ps1 .\build\GitVersionVsoTaskBuild\task.json $env:GitVersion_Major $env:GitVersion_Minor $env:GitVersion_Patch
27
28
- cmd : 7z a "GitVersionVsoBuildStep_%GitVersion_NuGetVersion%.zip" .\build\GitVersionVsoTaskBuild\*.*
28
29
- cmd : appveyor PushArtifact "GitVersionVsoBuildStep_%GitVersion_NuGetVersion%.zip"
29
30
Original file line number Diff line number Diff line change
1
+ param (
2
+ [string ] $filePath ,
3
+ [string ] $major ,
4
+ [string ] $minor ,
5
+ [string ] $patch
6
+ )
7
+
8
+ # Get the task.json as a powershell object
9
+ $task = Get-Content - Raw - Path $filePath | ConvertFrom-Json
10
+
11
+ $task.version.Major = $major
12
+ $task.version.Minor = $minor
13
+ $task.version.Patch = $patch
14
+
15
+ # get this as a string again
16
+
17
+ ConvertTo-Json $task | Set-Content - Path $filePath
You can’t perform that action at this time.
0 commit comments