vcpkg/versions/m-/ms-gsl.json
Billy O'Neal b295670e4b
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

135 lines
3.6 KiB
JSON

{
"versions": [
{
"git-tree": "d51947d40835a72b1728c68ca8587e04e3f8e1e2",
"version-string": "3.1.0",
"port-version": 1
},
{
"git-tree": "75aed40fd77dd1c0f123fe92df90d3aef55e7466",
"version-string": "3.1.0",
"port-version": 0
},
{
"git-tree": "654bd029ae281df6dc5594bb136ffdbe6361c588",
"version-string": "3.0.1",
"port-version": 0
},
{
"git-tree": "41b5c0431c3382db1de85e96ac6a8be2ceca1125",
"version-string": "3.0.0",
"port-version": 0
},
{
"git-tree": "a6df92e1447a5b45c16d50744ce5dcec3c54baf9",
"version-string": "2.1.0",
"port-version": 0
},
{
"git-tree": "8b49029d61352da39803ba6b2c815bee9dbe8ec8",
"version-string": "2019-07-11",
"port-version": 0
},
{
"git-tree": "4e3de250571b05ec1201a3913c76e33ae1f3c56c",
"version-string": "2019-04-19",
"port-version": 0
},
{
"git-tree": "e4567ef1517b2928d2128ff1f7d0387412a8a6bb",
"version-string": "2019-01-18",
"port-version": 0
},
{
"git-tree": "df14114c8016f39ff7797093615d196ceae2f9d3",
"version-string": "2019-01-15",
"port-version": 0
},
{
"git-tree": "ca140e80e01466b0b727e1b039ad9c610edf32a4",
"version-string": "2018-12-14",
"port-version": 0
},
{
"git-tree": "a36e0e8665f182ac8207aaadd5827ef27f0c5f7c",
"version-string": "2018-11-08",
"port-version": 0
},
{
"git-tree": "0fd1e71ebef788863641483e2d41abfc83590836",
"version-string": "2018-09-18",
"port-version": 0
},
{
"git-tree": "3913836087c786a705c7a83408e21c5f1b9e17ff",
"version-string": "2018-08-03",
"port-version": 0
},
{
"git-tree": "4839663c44968fcbc79c3f33f2783655744f4e8a",
"version-string": "2018-07-30",
"port-version": 0
},
{
"git-tree": "0d28abf5c16ff13ba787c1457cf9db67c95ee5c6",
"version-string": "2018-06-15",
"port-version": 0
},
{
"git-tree": "13a3460cb16a6f7de12dc3d1aa9c847b334e813a",
"version-string": "2018-06-12",
"port-version": 0
},
{
"git-tree": "4e1356da34a96964fc8b612bd99a24e8e5c49e16",
"version-string": "2018-05-17",
"port-version": 0
},
{
"git-tree": "b96fbc685a0a9b3219905e2470d992c4e29e430b",
"version-string": "2018-05-01",
"port-version": 0
},
{
"git-tree": "60264df907af96b1ab69bbf46ee2ee4d9befc2bf",
"version-string": "2018-04-25",
"port-version": 0
},
{
"git-tree": "1794c9a7b6a9fd0b275259e053a7697b16778ad0",
"version-string": "2018-03-17",
"port-version": 0
},
{
"git-tree": "2367d71b3ca048ce3c66b692102f5d04b5bd14a7",
"version-string": "2018-03-07",
"port-version": 0
},
{
"git-tree": "a59106e8559519103dbace593e6f29ee272c171a",
"version-string": "2018-03-03",
"port-version": 0
},
{
"git-tree": "4c935e8cb82d46941eec530cf1cd0429df00e7d6",
"version-string": "2018-02-25",
"port-version": 0
},
{
"git-tree": "0864fe6ea70e6ca2459f7b546ce477443b4b0eb9",
"version-string": "20171204-9d65e74400976b3509833f49b16d401600c7317d",
"port-version": 0
},
{
"git-tree": "16aa60b828fbea27c553101c636030afe5230634",
"version-string": "20171104-d10ebc6555b627c9d1196076a78467e7be505987",
"port-version": 0
},
{
"git-tree": "d6f9c5d16d0bb6077a01971d0762ae8b98de2c27",
"version-string": "20170425-8b320e3f5d016f953e55dfc7ec8694c1349d3fe4",
"port-version": 0
}
]
}