Last active
January 27, 2016 21:48
-
-
Save Fireforge/65b2fa7950973fdc3657 to your computer and use it in GitHub Desktop.
Nuget Package push Powershell script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# push.ps1 | |
# | |
# A simple script to package and push a Nuget package from a Visual Studio C# project. | |
# `nuget.exe` must be on the path or otherwise available to the script (Package Manager Console) | |
Set-Location -Path $PSScriptRoot | |
# project parameters | |
$projname = "MyProject" | |
$pushdir = "path\to\nupkgs" | |
rm *.nupkg | |
# Push out the release version for use in portable apps | |
nuget pack $PSScriptRoot\$projname.csproj -build | |
$nupkg = ls *.nupkg | |
nuget push -source $pushdir $nupkg | |
rm $nupkg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment