`dotnet --version` doesn't work on runtime (not SDK install)
See original GitHub issueSteps to reproduce
download and install dotnet-runtime-2.0.0-win-x64.exe
from https://download.microsoft.com/download/5/6/B/56BFEF92-9045-4414-970C-AB31E0FC07EC/dotnet-runtime-2.0.0-win-x64.exe
open powershell window
call dotnet --version
Expected behavior
expect that version 2.0.0 would be displayed
Actual behavior
Did you mean to run dotnet SDK commands? Please install dotnet SDK from:
http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409
Actual output
PS C:\Users\lee.campbell> dotnet
Usage: dotnet [options]
Usage: dotnet [path-to-application]
Options:
-h|--help Display help.
--version Display version.
path-to-application:
The path to an application .dll file to execute.
PS C:\Users\lee.campbell> dotnet --version
Did you mean to run dotnet SDK commands? Please install dotnet SDK from:
http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409
PS C:\Users\lee.campbell> dotnet --info
Microsoft .NET Core Shared Framework Host
Version : 2.0.0
Build : e8b8861ac7faf042c87a5c2f9f2d04c98b69f28d
PS C:\Users\lee.campbell>
Note that while I can get the version by running dotnet --info
the default no-argument output tells me to run dotnet --version
which is then unsupported.
It seems that if this is unsupported, then it should suggest I run the --info, or alternatively support should be implemented
Issue Analytics
- State:
- Created 6 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
c# - .NET SDK's Not Installing Correctly
Now try it out, open a new command prompt or PowerShell, and type dotnet --info . It should tell you that you have...
Read more >NETSDK1045: The current .NET SDK does not support ...
This error occurs when the build tools can't find the version of the .NET SDK that's needed to build a project. This is...
Read more >VS2019 and dotnet --info says SDK isn't installed, even ...
After installing the .NET Core Runtime (2.2.3) on top of the .NET Core SDK (2.2.202), VS2019 is unable to load my Core projects....
Read more >Why don't any of these methods work for installing .Net ...
sudo apt update sudo apt install dotnet-sdk-6.0. And I got the last version ... The following simple command has fixed the problem for...
Read more >How do I run the .NET SDK? The SDK and runtime appear ...
The SDK and runtime appear to be installed but the SDK won't run. ... No .NET SDKs were found. dotnet --info I get....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks for the feedback, but I think your comment is missing my point. I am not entering into a discussion on SDK vs runtime vs CLI. This issue is simply pointing out the internal inconsistency of the tool. i.e. Typing
dotnet
tells you that you should usedotnet --version
, however that command is not supported.Hi… I am getting the same error in Amazon Linux… I tried multiple ways to re-install by using earlier comments but still same issue. Please find the error below: