PS scripts to automate NuGet/Chocolatey package generation. Also eliminated VC redist dependency in Chocolatey spec

This commit is contained in:
jonathan pickett
2014-04-02 16:48:17 -07:00
parent 0df3c6b4b4
commit e2a48cd715
3 changed files with 41 additions and 3 deletions
+24
View File
@@ -0,0 +1,24 @@
$CurDir = split-path -parent $MyInvocation.MyCommand.Definition
$ChocolateyDir = $CurDir + "\chocolatey"
$NugetDir = $CurDir + "\nuget"
$PackagesDir = $CurDir + "\packages"
If (Test-Path $PackagesDir){
Remove-Item $PackagesDir -recurse | Out-Null
}
New-Item $PackagesDir -type directory | Out-Null
New-Item ($PackagesDir+"\Chocolatey") -type directory | Out-Null
New-Item ($PackagesDir+"\NuGet") -type directory | Out-Null
Set-Location $ChocolateyDir
invoke-expression cpack
Copy-Item *.nupkg ..\packages\Chocolatey
Set-Location $NugetDir
invoke-expression "NuGet Pack Redis.nuspec"
Copy-Item *.nupkg ..\packages\NuGet
Set-Location $CurDir
Write-Host "The .nuspec files are in the 'packages' directory" -foregroundcolor black -backgroundcolor green
+17
View File
@@ -0,0 +1,17 @@
[Reflection.Assembly]::LoadWithPartialName("System.IO.Compression.FileSystem") | Out-Null
$CurDir = split-path -parent $MyInvocation.MyCommand.Definition
$SourceZip = [System.IO.Path]::Combine($CurDir, "..\..\bin\Release\redis-2.8.4.zip" )
$Destination = [System.IO.Path]::Combine($CurDir, "signed_binaries" )
[System.IO.Directory]::CreateDirectory($Destination) | Out-Null
ForEach( $file in [System.IO.Directory]::EnumerateFiles($Destination) ) {
[System.IO.File]::Delete($file)
}
[System.IO.Compression.ZipFile]::ExtractToDirectory($SourceZip,$Destination)
Write-Host "Binaries copied from $SourceZip to $Destination" -foregroundcolor black -backgroundcolor green
Write-Host "Sign these and then run CreatePackages.ps1" -foregroundcolor red -backgroundcolor yellow
-3
View File
@@ -14,9 +14,6 @@
<licenseUrl>https://github.com/MSOpenTech/redis/blob/2.8.4_msopen/license.txt</licenseUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<iconUrl>http://redis.io/images/redis.png</iconUrl>
<dependencies>
<dependency id="vcredist2012" />
</dependencies>
<releaseNotes></releaseNotes>
</metadata>
<files>