Unable to install any tools using dotnet tool install
See original GitHub issueI am trying to install a global tool. However, I always get the same error message regardless of the tool I try to install (e.g. also for dotnetsay
):
C:\Users\Christer\Source\Repos\faketest>dotnet tool install fake-cli -g
Failed to install tool package 'fake-cli': Could not find a part of the path 'C:\Users\Christer\.dotnet\tools\.store\.stage\0qd2mqpa.m45\fake-cli'.
Tool 'fake-cli' failed to install. This failure may have been caused by:
* You are attempting to install a preview release and did not use the --version option to specify the version.
* A package by this name was found, but it was not a .NET Core tool.
* The required NuGet feed cannot be accessed, perhaps because of an Internet connection problem.
* You mistyped the name of the tool.
I have tried for several hours to clean up my environment, PATH, reinstall VS, etc., but I can’t figure out why this doesn’t work.
I get the same problem when specifying a tool path.
I’m sorry for what is evidently a support request, but I haven’t found anything on google, SO, etc. I’m one step short of reinstalling my whole system and have nowhere else to turn.
What could be wrong? Why doesn’t this work? What could I do to troubleshoot further?
dotnet info:
C:\Users\Christer\Source\Repos\faketest>dotnet --info
.NET Core SDK (reflecting any global.json):
Version: 2.1.700
Commit: c2ef055a0f
Runtime Environment:
OS Name: Windows
OS Version: 10.0.17763
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\2.1.700\
Host (useful for support):
Version: 2.2.5
Commit: 0a3c9209c0
.NET Core SDKs installed:
2.1.700 [C:\Program Files\dotnet\sdk]
2.2.300 [C:\Program Files\dotnet\sdk]
.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.11 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.2.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.11 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.2.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.11 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.2.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
To install additional .NET Core runtimes or SDKs:
https://aka.ms/dotnet-download
Issue Analytics
- State:
- Created 4 years ago
- Comments:12
Top Results From Across the Web
Troubleshoot .NET tool usage issues
Tool installation requires access to the NuGet feed that contains the tool package. It fails if the feed isn't available. You can alter...
Read more >Dotnet fails to install tools - Microsoft Q&A
I cannot install the AWS Lambda tools in dotnet: $ dotnet tool install -g Amazon.Lambda.Tools error NU1100: Unable to resolve ...
Read more >dotnet tool install command - .NET CLI
The dotnet tool install command provides a way for you to install .NET tools on your machine. To use the command, you specify...
Read more >Tutorial: Install and use a .NET global tool - .NET CLI
This tutorial teaches you how to install and use a global tool. You use a tool that you create in the first tutorial...
Read more >dotnet-tool-install: Installs the specified .NET tool on ...
The dotnet tool install command provides a way for you to install .NET tools on your machine. To use the command, you specify...
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
Nevermind, I found the issue. I removed the
MSBuildSDKsPath
environment variable and now everything works fine.For me worked the following solution from https://github.com/dotnet/sdk/issues/4156#issuecomment-601791960