[Windows] Fix version output for vcpkg (#2142)

* change version output for vcpkg

* change to short commit id

* minor change

* minor change

* minor change

* resolve issue
This commit is contained in:
Dibir Magomedsaygitov
2020-12-04 10:21:21 +03:00
committed by GitHub
parent f415c1f30f
commit 84744e30de

View File

@@ -103,7 +103,8 @@ function Get-ChocoVersion {
function Get-VcpkgVersion { function Get-VcpkgVersion {
($(vcpkg version) | Out-String) -match "version (?<version>\d+\.\d+\.\d+)" | Out-Null ($(vcpkg version) | Out-String) -match "version (?<version>\d+\.\d+\.\d+)" | Out-Null
$vcpkgVersion = $Matches.Version $vcpkgVersion = $Matches.Version
return "Vcpkg $vcpkgVersion" $commitId = git -C "C:\vcpkg" rev-parse --short HEAD
return "Vcpkg $vcpkgVersion (build from master <$commitId>)"
} }
function Get-NPMVersion { function Get-NPMVersion {