Skip to content
This repository was archived by the owner on Jan 19, 2019. It is now read-only.

CLI: Work with MSBuild projects - #16

Merged
bricelam merged 1 commit into
aspnet:devfrom
bricelam:csproj
Oct 26, 2016
Merged

bricelam merged 1 commit into
aspnet:devfrom
bricelam:csproj

Conversation

@bricelam

@bricelam bricelam commented Oct 25, 2016 •

Copy link
Copy Markdown
Contributor

Resolves dotnet/efcore#6139

This is based on the prototype by @natemcmaster.

TODO

  • Add tests (dotnet restore3 had some issues with stars in versions)
  • React to CLI changes
    • Color isn't flowing through
    • There's lot of output coming from from MSBuild
  • Ensure NuGet commands work with VS "15" csproj
  • Remove project.json support (not yet)

cc @Eilon

@dnfclas

dnfclas commented Oct 25, 2016

Copy link
Copy Markdown

Hi @bricelam, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!

The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.

TTYL, DNFBOT;

@Eilon Eilon left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though there's certainly a few things I don't know in great detail here, this looks amazingly simple and straightforward. So, "approved" for now, pending your remaining work items.

if (result.ExitCode != 0)
{
throw new OperationErrorException(
$"Couldn't read metadata for project '{filePath}'. Ensure the package 'Microsoft.EntityFrameowrkCore.Tools' is installed.");

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

EntityFrameowrkCore 😄

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be fair, it's not a framework...


if (Directory.Exists(filePath))
{
var msbuildFiles = Directory.EnumerateFiles(filePath, "*.*proj").Take(2).ToList();

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will match xproj too. Probably better to filter that since it's not actually an "MSBuild" project.

@bricelam
bricelam merged commit dbac8c6 into aspnet:dev Oct 26, 2016
@bricelam
bricelam deleted the csproj branch October 26, 2016 17:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants