Last active
April 2, 2021 07:37
-
-
Save ebicoglu/177f48f5fad1bcc49645c0939af4ae76 to your computer and use it in GitHub Desktop.
Updates ABP CLI and ABP Suite to the latest version (including previews)
This file contains 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
Set-PSDebug -Trace 0 | |
$packageName = "volo.abp.cli" | |
$output = dotnet tool search $packageName --prerelease --take 1 | |
$outputString = ("" + $output) | |
$indexOfVersionLine = $outputString.IndexOf($packageName) | |
$latestVersion = $outputString.substring($indexOfVersionLine + $packageName.length).trim().split(" ")[0].trim() | |
Write-Host "Updating "$packageName" to" $latestVersion | |
dotnet tool update -g $packageName --version $latestVersion | |
Write-Host "Updating ABP Suite" | |
abp suite update --preview | |
Read-Host -Prompt "Press Enter to exit" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Info:
dotnet tool
doesn't have parameter to include the preview versions when you update/install a package.You need to provide the version parameter to install any preview (RC) version.
I created a feature request to Microsoft to support this functionality.
So we need to find the latest preview version and add this to
--version
parameter in the command.