efcore
efcore copied to clipboard
PMC Tools: Build only the active project, not the whole solution
We tried to do this before, but ran into issues. Hopefully the project system has matured such that it is now possible. See #9515 for more discussion.
Note, this only applies to the PMC Tools. The CLI tools already only build the startup project.
Thank you @bricelam . That wasn't made clear or I missed it on other threads. Knowing that, I can probably build a tooling workaround, except for the fact that I have other issues getting CLI working for EF Core 2.0 :( . I'll switch my focus to fixing those.
It would be neat to have this, as this is the only reason I typically use PMC. 😁
Unfortunately using the dotnet ef equivalent seems to invalidate all projects in my solution, seemingly replacing one problem with another.
First, I run dotnet clean and SHIFT-CTRL-B on my SLN:
========== Build: 130 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
SHIFT-CTRL-B again to be sure:
========== Build: 0 succeeded, 0 failed, 130 up-to-date, 0 skipped ==========
I then run the following commands:
dotnet ef database drop -f -v --project Starbeam.Model.Schema --startup-project Starbeam.Model.Schema
dotnet ef migrations remove -v --project Starbeam.Model.Schema --startup-project Starbeam.Model.Schema
dotnet ef migrations add Initial -v --project Starbeam.Model.Schema --startup-project Starbeam.Model.Schema
Finally, after that is complete, I run SHIFT-CTRL-B once more:
========== Build: 129 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
FWIW this is with 6.0.0-rc.2.21452.6 tools.