Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert projects in this repo to use ProjectReference #4246

Closed
24 tasks done
natemcmaster opened this issue Nov 27, 2018 · 8 comments
Closed
24 tasks done

Convert projects in this repo to use ProjectReference #4246

natemcmaster opened this issue Nov 27, 2018 · 8 comments
Assignees
Labels
area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework Done This issue has been fixed

Comments

@natemcmaster
Copy link
Contributor

natemcmaster commented Nov 27, 2018

Follow-up to #3598.

The first phase of reducing repos was to merge the source code into a single repo. The second phase is to convert them from isolated folders of code with PackageReference across repo boundaries, to projects which use ProjectReference.

We've already started some of this work. See #4013 for example and https://github.com/aspnet/AspNetCore/tree/master/src/DataProtection.

As done in #4013, we implement this using <Reference> items in .csproj and custom Reference resolution targets. This is done so we can automatically pick the right versions of assemblies to used based on conditions such as, is this a test project? is this branch building a patch or a new minor release? what versions were used in the last stable release? etc.

See also https://github.com/aspnet/specs/blob/master/runtime/design-notes/2018-10-03-mondo-source-org.md for the spec on source code organization.

Repo groups to convert

@natemcmaster natemcmaster added the area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework label Nov 27, 2018
@natemcmaster natemcmaster self-assigned this Nov 27, 2018
@natemcmaster
Copy link
Contributor Author

cc @jkotalik who is helping do this for src/IISIntegration/

@jkotalik
Copy link
Contributor

Once I get this done for IISIntegration, I'll do other repos too. IISIntegration was significantly more difficult to port than other repos (due to native dependencies).

@natemcmaster
Copy link
Contributor Author

I'm adding a checklist to the original issue to track the groups of subrepos that we need to convert. Let's start by doing these one at a time.

@natemcmaster
Copy link
Contributor Author

FYI - here is the script I've been using to convert Project/Package refs to just <Reference>

https://gist.github.com/natemcmaster/40556be8f8d821a225f48afbd743bbeb

Usage:

PS> Get-ChildItem *.csproj -Recurse | % { C:\src\scripts\mk_ref.ps1 $_ }

@natemcmaster
Copy link
Contributor Author

Once #4954 is merged and makes its way up to master, I think we should be unblocked to convert Components and Mvc.

FYI @SteveSandersonMS @javiercn - the refactoring on Components is likely to be fairly disruptive. Do you have any big changes that need to go in this week?

@SteveSandersonMS
Copy link
Member

Thanks for the heads-up, @natemcmaster! I’d definitely like to merge #5166 before any other disruptive change goes in. Should be ready to merge as soon as it’s reviewed.

@SteveSandersonMS
Copy link
Member

@natemcmaster #5166 is merged now, so you should be OK to do changes to Components to use <Reference> etc. When doing so, please be sure to run the E2E tests (Microsoft.AspNetCore.Components.E2ETest) manually to verify that it hasn't broken aspects of how we bundle stuff for both server and client-side execution. We're going to run those E2E tests automatically in CI soon (#5158) but for now it's manual.

@natemcmaster
Copy link
Contributor Author

@SteveSandersonMS I started looking into this but found code in src/Components/ that I'm unsure about, specifically, the code in src/Components/blazor/. Can you take a look at the details I posted in this comment? https://github.com/aspnet/AspNetCore-Internal/issues/1535#issuecomment-450685185

natemcmaster added a commit that referenced this issue Jan 9, 2019
Part of #4246 

Changes:
* Update source code layout to follow the new conventions for this repo
* Update project files to use `<Reference>`
* Update targets to build NPM packages
* Update BuildTools to support custom 'restore' and 'test' targets
natemcmaster added a commit that referenced this issue Jan 16, 2019
This addresses #4246 for src/Components/. A few other changes were necessary because components had been using stale dependencies.
@natemcmaster natemcmaster added this to the 3.0.0-preview3 milestone Jan 23, 2019
@natemcmaster natemcmaster added Done This issue has been fixed and removed 2 - Working labels Jan 23, 2019
@ghost ghost locked as resolved and limited conversation to collaborators Dec 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework Done This issue has been fixed
Projects
None yet
Development

No branches or pull requests

5 participants