vcpkg/versions/t-/taocpp-json.json

45 lines
1.1 KiB
JSON
Raw Normal View History

{
"versions": [
{
"git-tree": "0f65d42ce52c1a7c42635e90f51af98f786ae9b2",
"version-date": "2020-09-14",
"port-version": 4
},
{
"git-tree": "3efce615deb5e4414df2c3731c1e8eae333d32c9",
"version-date": "2020-09-14",
"port-version": 3
},
{
"git-tree": "d3ae444025a6267cf41b462f77061757254bc829",
"version-string": "2020-09-14",
"port-version": 2
},
Bulk convert control files. (#19986) ``` function Convert-Control { Param($full) .\vcpkg.exe format-manifest $full $root = $full.Substring(0, $full.Length - 7) # CONTROL $new = $root + 'vcpkg.json' $content = Get-Content -Raw $new $asJson = ConvertFrom-Json $content -AsHashtable -Depth 100 $oldVersion = $asJson['port-version'] if ($null -eq $oldVersion) { $oldVersionFull = $asJson['version-string'] Write-Host "Got version $oldVersionFull" $match = [System.Text.RegularExpressions.Regex]::Match($oldVersionFull, '^(.+)-(\d+)$') if ($match.Success -and -not [System.Text.RegularExpressions.Regex]::IsMatch($oldVersionFull, '^\d\d\d\d-\d\d-\d\d$')) { $newFullVersion = [string]$match.Groups[1].Value $oldVersion = [int]$match.Groups[2].Value Write-Host "newFullVersion $newFullVersion oldVersion $oldVersion" $newVersion = $oldVersion + 1 $asJson['version-string'] = $newFullVersion Write-Host "Previous version for $full extracted from version field -- setting version-string $newFullVersion and port-version $newVersion" } else { Write-Host "No previous version for $full -- setting 1" $newVersion = 1 } } else { $newVersion = [int]$oldVersion + 1 Write-Host "New version for $full : $newVersion" } $asJson['port-version'] = $newVersion $content = ConvertTo-Json $asJson -Depth 100 Set-Content -Path $new -Value $content .\vcpkg.exe format-manifest $new } Get-ChildItem ports\CONTROL -Recurse | Foreach-Object { Convert-Control $_.FullName } git commit -am "this message" .\vcpkg.exe x-add-version -all git commit -a --amend ```
2021-09-09 01:24:04 -07:00
{
"git-tree": "afe8907661864659e89e9fc421415b2687390c03",
"version-string": "2020-09-14",
"port-version": 1
},
{
"git-tree": "1f514b2100e6f510ec9fe39625c67e050f0910e0",
"version-string": "2020-09-14",
"port-version": 0
},
{
"git-tree": "e90cd293087f49812acd65105f83db565d0b71a2",
"version-string": "2019-07-11",
"port-version": 0
},
{
"git-tree": "dccd7a3e684a35f08501928c40b1409b8a6fb2d8",
"version-string": "2019-05-08",
"port-version": 0
},
{
"git-tree": "e41d989a56709ec651f6cfd5e9f411e1fad1837e",
"version-string": "2019-04-29-1",
"port-version": 0
}
]
}