Add NuGet package tools

This commit is contained in:
Davipb authored and Lukas Dürrenberger committed 2019-01-23 22:59:18 +01:00
1 parent 61f17e3c1d
commit d8e19e74ed
14 files changed
+680

No files matched your search

+43
View File
@@ -0,0 +1,43 @@
Param(
[Parameter(Position = 0)]
[string] $RID
)
$ErrorActionPreference = "Stop"
if (-not $RID ) {
Write-Output "No RID specified, building all known RIDs"
./build.docker.ps1 "alpine-x64"
./build.docker.ps1 "debian-x64"
./build.docker.ps1 "fedora-x64"
exit
}
$Image = $null
$Shell = $null
switch ($RID) {
'alpine-x64' {
$Image = 'alpine'
$Shell = '/bin/sh'
}
'debian-x64' {
$Image = 'debian'
$Shell = '/bin/bash'
}
'fedora-x64' {
$Image = 'fedora'
$Shell = '/bin/bash'
}
Default {
Write-Error "Unknown Runtime Identifier $RID"
exit
}
}
Write-Host "Building $RID with image $Image using $Shell"
$RepoRoot = (Get-Item (git rev-parse --show-toplevel)).FullName
docker run --rm --mount "type=bind,source=$RepoRoot,destination=/csfml/" $Image $Shell -c "cd /csfml/tools/nuget/; ./docker.$RID.sh"
exit $LastExitCode