Skip to content

Commit c0a29ff

Browse files
author
Balakrishnan Ranganathan
committed
Script to pack and push and cleanup after
1 parent 00388c8 commit c0a29ff

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

PackAndPush.ps1

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
param(
2+
[Parameter(Mandatory = $true)]
3+
[string] $NuspecVersion
4+
)
5+
6+
function Activate() {
7+
$confirmation = Read-Host -Prompt "Are you sure you want to push v$NuspecVersion (y/n)"
8+
if (!($confirmation.ToLower() -eq "y"))
9+
{
10+
return;
11+
}
12+
13+
nuget pack .\Watts.nuspec
14+
nuget push ".\WebApiToTypeScript.$NuspecVersion.nupkg" -Source https://www.nuget.org/api/v2/package
15+
16+
Remove-Item *.nupkg -Force
17+
}
18+
19+
Activate

0 commit comments

Comments
 (0)