From 553f80f19bd1eae47b81766fbad88ab32b1471c2 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Mon, 4 Jun 2018 16:59:57 -0400 Subject: [PATCH] switch for choco nopush --- scripts/choco-update.ps1 | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/scripts/choco-update.ps1 b/scripts/choco-update.ps1 index d3ed226434e..39da637a424 100644 --- a/scripts/choco-update.ps1 +++ b/scripts/choco-update.ps1 @@ -1,4 +1,8 @@ -# To run: +param ( + [switch] $nopush, +) + +# To run: # .\choco-update.ps1 $dir = Split-Path -Parent $MyInvocation.MyCommand.Path; @@ -22,6 +26,9 @@ $srcPackage = $rootDir + "\package.json"; $srcPackageVersion = (Get-Content -Raw -Path $srcPackage | ConvertFrom-Json).version; $nuspec = $distChocoDir + "\bitwarden-cli.nuspec"; choco pack $nuspec --version $srcPackageVersion --out $distChocoDir -cd $distChocoDir -choco push -cd $rootDir + +if (!$nopush) { + cd $distChocoDir + choco push + cd $rootDir +}