Powershell Run Exe / Commands

Date: 2021-09-20
$version = '1.88.3'

if (-not(Test-Path -Path "./nuget.exe" -PathType Leaf)) {
    # download latest nuget.exe
    &"curl.exe" @("https://dist.nuget.org/win-x86-commandline/latest/nuget.exe", "-o", "nuget.exe")
}

# create
&"./nuget.exe" @("pack", "-exclude", "nuget commands.txt", "-properties", "id=Uniconta.Assemblies;version=""$version""")

# publish
&"./nuget.exe" @("push", "Uniconta.Assemblies.$version.nupkg", "-Source", "https://nuget.test.com/nuget", "THE_KEY")

# delete
# &'nuget.exe delete Uniconta.Assemblies 1.86.0 -Source https://nuget.test.com/nuget -apikey THE_KEY'
52880cookie-checkPowershell Run Exe / Commands