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

Remove bootstrap.proj #5142

Merged
merged 1 commit into from
May 4, 2023
Merged

Remove bootstrap.proj #5142

merged 1 commit into from
May 4, 2023

Conversation

jeffkl
Copy link
Contributor

@jeffkl jeffkl commented Apr 20, 2023

Bug

Fixes: https://github.com/NuGet/Client.Engineering/issues/2186

Regression? Last working version:

Description

This removes bootstrap.proj and replaces it with more retail MSBuild logic and allows a user to clone our repository and build it as long as they have Visual Studio and .NET SDK installed.

I had to re-recreate #5070 since GitHub won't let me re-open it. I will address the comments from it in this PR.

The main goal is to make it so nothing needs to be initialized, the act of building the repo is what pulls in all necessary dependencies.

PR Checklist

  • PR has a meaningful title

  • PR has a linked issue.

  • Described changes

  • Tests

    • Automated tests added
    • OR
    • Test exception
    • OR
    • N/A
  • Documentation

    • Documentation PR or issue filled
    • OR
    • N/A

@jeffkl jeffkl self-assigned this Apr 20, 2023
@jeffkl jeffkl requested a review from a team as a code owner April 20, 2023 20:51
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This replaces BuildValidator.ps1 which depended on bootstrap.proj to pull down a package (NuGetValidator) and on the VSIX already being built. Now that its an MSBuild project, we will get binary logs from hosted builds and in this case I'm embedding the text log from NuGetValidator in the binary log so we'll get more logs than before.

@@ -1,7 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0">
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'README.md'))\packages\Microsoft.VisualStudioEng.MicroBuild.Core\1.0.0\build\Microsoft.VisualStudioEng.MicroBuild.Core.props" Condition="Exists('$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), &quot;README.md&quot;))\packages\Microsoft.VisualStudioEng.MicroBuild.Core\1.0.0\build\Microsoft.VisualStudioEng.MicroBuild.Core.props')" />
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@@ -114,7 +115,7 @@
Outputs="$(PathToMergedNuGetExe)"
Condition="'$(BuildingInsideVisualStudio)' != 'true' and '$(SkipILMergeOfNuGetExe)' != 'true'" >
<PropertyGroup>
<IlmergeCommand>$(ILMergeExePath) /lib:$(OutputPath) /out:$(PathToMergedNuGetExe) @(MergeAllowDup -> '/allowdup:%(Identity)', ' ') /log:$(OutputPath)IlMergeLog.txt</IlmergeCommand>
<IlmergeCommand>$(ILMergeConsolePath) /lib:$(OutputPath) /out:$(PathToMergedNuGetExe) @(MergeAllowDup -> '/allowdup:%(Identity)', ' ') /log:$(OutputPath)IlMergeLog.txt</IlmergeCommand>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The ILMerge package provides this MSBuild property for us automatically!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This replaces CreateEndToEndTestPackage.ps1 as an MSBuild project so we can get binary logs from hosted builds. It's also using my Microsoft.Build.Artifacts package which is able to stage artifacts very quickly since it has robocopy-like logic.

@jeffkl jeffkl force-pushed the dev-jeffkl-reduce-bootstrap branch from d336a5e to 7eaa3a7 Compare April 20, 2023 21:17
@zivkan
Copy link
Member

zivkan commented Apr 21, 2023

Oh, please don't merge this until after M2 mode, to minimize risk of blocking urgent insertions

@jeffkl jeffkl force-pushed the dev-jeffkl-reduce-bootstrap branch from 7eaa3a7 to 651aba4 Compare May 3, 2023 15:08
@jeffkl jeffkl requested a review from zivkan May 3, 2023 15:31
@jeffkl jeffkl merged commit 43b0ec5 into dev May 4, 2023
@jeffkl jeffkl deleted the dev-jeffkl-reduce-bootstrap branch May 4, 2023 20:03
jeffkl added a commit that referenced this pull request May 9, 2023
jeffkl added a commit that referenced this pull request May 9, 2023
jeffkl added a commit that referenced this pull request May 9, 2023
@jeffkl jeffkl mentioned this pull request May 10, 2023
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants