ProjectDependenciesCommandFactory cannot find command in desktop .NET class library project
See original GitHub issueSteps to reproduce
Create a sample project using dotnet-ef
{
"version": "1.0.0-*",
"buildOptions": {
"emitEntryPoint": false
},
"dependencies": {
"Microsoft.EntityFrameworkCore.Sqlite": "1.0.0-*",
"Microsoft.EntityFrameworkCore.Tools": {
"type": "build",
"version": "1.0.0-*"
}
},
"frameworks": {
"net451":{}
},
"tools": {
"Microsoft.EntityFrameworkCore.Tools": {
"imports": [
"portable-net451+win8"
],
"version": "1.0.0-*"
}
}
}
dotnet restore
dotnet ef migrations list --verbose
Expected behavior
dotnet-ef.dll (in Microsoft.EntityFrameworkCore.Tools) should dispatch via ProjectDependenciesCommandFactory to Microsoft.EntityFrameworkCore.Tools.Cli.exe (a project dependency) and list all migrations in the project
Actual behavior
No executable found matching command "Microsoft.EntityFrameworkCore.Tools.Cli"
ProjectDependenciesCommandFactory
tries to find a command in bin/Debug/net451/win7-x64
, but the command is actually in bin/Debug/net451/
Environment data
dotnet --info
output:
.NET Command Line Tools (1.0.0-rc2-002673)
Product Information:
Version: 1.0.0-rc2-002673
Commit Sha: c0aeb91d61
Runtime Environment:
OS Name: Windows
OS Version: 10.0.10586
OS Platform: Windows
RID: win10-x64
"Microsoft.DotNet.Cli.Utils/1.0.0-rc2-002673"
Issue Analytics
- State:
- Created 7 years ago
- Comments:14 (14 by maintainers)
Top Results From Across the Web
Cannot invoke project dependency command on a library
ProjectDependenciesCommandFactory should create and execute a command on the netstandard library. Actual behavior. On a library project. Running ...
Read more >Why can't I reference my class library?
I right click the Bin folder or Project and select Add Reference, then select my Class Library Project, it adds the 15 or...
Read more >Trying to make a class class Library and getting some odd ...
Hi All. The title tells the table. I try to all the dll to a project and get the error shown in the...
Read more >Tutorial: Create a .NET class library using Visual Studio
Right-click on the solution in Solution Explorer and select Add > New Project. On the Add a new project page, enter library in...
Read more >How to convert an application project to class library ...
In the Solutions Explorer window, right-click the exe project and then select Properties in the popup. Then change the Output type from Windows...
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 Free
Top 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
@brthor I was about to comment the same thing 😃
Fixed by dotnet/cli#2933