-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Convert Middleware and Agent.Host packages to source packages #51335
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
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| [*.cs] | ||
|
|
||
| # IDE0240: Remove redundant nullable directive | ||
| # The directive needs to be included since all sources in a source package are considered generated code | ||
| # when referenced from a project via package reference. | ||
| dotnet_diagnostic.IDE0240.severity = none |
42 changes: 42 additions & 0 deletions
42
src/BuiltInTools/HotReloadAgent.Host/Microsoft.DotNet.HotReload.Agent.Host.Package.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,42 @@ | ||
| <Project Sdk="Microsoft.NET.Sdk"> | ||
|
|
||
| <PropertyGroup> | ||
| <!-- | ||
| This code may be injected into a .NET 6.0+ app. | ||
|
|
||
| When updating these also update ProjectReferences in dotnet-watch.csproj | ||
| and HotReloadAppModel.TryGetStartupHookPath. | ||
| --> | ||
| <TargetFrameworks>net6.0;net10.0</TargetFrameworks> | ||
| <DisableTransitiveFrameworkReferenceDownloads Condition="'$(DotNetBuildSourceOnly)' == 'true'">true</DisableTransitiveFrameworkReferenceDownloads> | ||
|
|
||
| <GenerateDocumentationFile>false</GenerateDocumentationFile> | ||
| <DebugType>none</DebugType> | ||
| <GenerateDependencyFile>false</GenerateDependencyFile> | ||
| <LangVersion>preview</LangVersion> | ||
|
|
||
| <!-- NuGet --> | ||
| <IsPackable>true</IsPackable> | ||
| <IsShipping>true</IsShipping> | ||
| <IsSourcePackage>true</IsSourcePackage> | ||
| <PackageId>Microsoft.DotNet.HotReload.Agent.Host</PackageId> | ||
| <IncludeBuildOutput>false</IncludeBuildOutput> | ||
| <PackageDescription>Package containing Hot Reload agent host.</PackageDescription> | ||
| <!-- Remove once https://github.com/NuGet/Home/issues/8583 is fixed --> | ||
| <NoWarn>$(NoWarn);NU5128</NoWarn> | ||
| </PropertyGroup> | ||
|
|
||
| <!-- Reference 6.0.0 targeting packs in Source Build --> | ||
| <ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true' and '$(TargetFramework)' == 'net6.0'"> | ||
| <FrameworkReference Update="Microsoft.NETCore.App" TargetingPackVersion="6.0.0" /> | ||
| </ItemGroup> | ||
|
|
||
| <Import Project="..\HotReloadAgent\Microsoft.DotNet.HotReload.Agent.projitems" Label="Shared" /> | ||
| <Import Project="..\HotReloadAgent.Data\Microsoft.DotNet.HotReload.Agent.Data.projitems" Label="Shared" /> | ||
| <Import Project="..\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.projitems" Label="Shared" /> | ||
|
|
||
| <!-- Make sure the shared source files do not require any global usings --> | ||
| <ItemGroup> | ||
| <Using Remove="@(Using)" /> | ||
| </ItemGroup> | ||
| </Project> |
14 changes: 14 additions & 0 deletions
14
src/BuiltInTools/HotReloadAgent.Host/Microsoft.DotNet.HotReload.Agent.Host.projitems
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
| <PropertyGroup> | ||
| <MSBuildAllProjects Condition="'$(MSBuildVersion)' == '' Or '$(MSBuildVersion)' < '16.0'">$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects> | ||
| <HasSharedItems>true</HasSharedItems> | ||
| <SharedGUID>15C936B2-901D-4A27-AFA6-89CF56F5EB20</SharedGUID> | ||
| </PropertyGroup> | ||
| <PropertyGroup Label="Configuration"> | ||
| <Import_RootNamespace>Microsoft.DotNet.HotReload</Import_RootNamespace> | ||
| </PropertyGroup> | ||
| <ItemGroup> | ||
| <Compile Include="$(MSBuildThisFileDirectory)**\*.cs" /> | ||
| </ItemGroup> | ||
| </Project> |
13 changes: 13 additions & 0 deletions
13
src/BuiltInTools/HotReloadAgent.Host/Microsoft.DotNet.HotReload.Agent.Host.shproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
| <PropertyGroup Label="Globals"> | ||
| <ProjectGuid>15C936B2-901D-4A27-AFA6-89CF56F5EB20</ProjectGuid> | ||
| <MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion> | ||
| </PropertyGroup> | ||
| <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> | ||
| <Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.Common.Default.props" /> | ||
| <Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.Common.props" /> | ||
| <PropertyGroup /> | ||
| <Import Project="Microsoft.DotNet.HotReload.Agent.Host.projitems" Label="Shared" /> | ||
| <Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.CSharp.targets" /> | ||
| </Project> |
5 changes: 5 additions & 0 deletions
5
...nTools/DotNetDeltaApplier/PipeListener.cs → ...Tools/HotReloadAgent.Host/PipeListener.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| [*.cs] | ||
|
|
||
| # IDE0240: Remove redundant nullable directive | ||
| # The directive needs to be included since all sources in a source package are considered generated code | ||
| # when referenced from a project via package reference. | ||
| dotnet_diagnostic.IDE0240.severity = none | ||
|
|
||
| [*.js] | ||
| indent_size = 2 |
2 changes: 2 additions & 0 deletions
2
...nTools/BrowserRefresh/ApplicationPaths.cs → ...nTools/Web.Middleware/ApplicationPaths.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
4 changes: 4 additions & 0 deletions
4
...rRefresh/BlazorWasmHotReloadMiddleware.cs → ...ddleware/BlazorWasmHotReloadMiddleware.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
...rowserRefresh/BrowserRefreshMiddleware.cs → ...eb.Middleware/BrowserRefreshMiddleware.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
...BrowserRefresh/BrowserScriptMiddleware.cs → ...Web.Middleware/BrowserScriptMiddleware.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
...tInTools/BrowserRefresh/HostingStartup.cs → ...tInTools/Web.Middleware/HostingStartup.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
src/BuiltInTools/Web.Middleware/Microsoft.DotNet.HotReload.Web.Middleware.Package.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| <Project Sdk="Microsoft.NET.Sdk"> | ||
|
|
||
| <PropertyGroup> | ||
| <!-- | ||
| This source code may be loaded by a .NET 6.0+ web server. | ||
| When updating the TFM also update minimal supported version in dotnet-watch.csproj and WebApplicationAppModel.cs. | ||
| --> | ||
| <TargetFrameworks>net6.0</TargetFrameworks> | ||
| <DisableTransitiveFrameworkReferenceDownloads Condition="'$(DotNetBuildSourceOnly)' == 'true'">true</DisableTransitiveFrameworkReferenceDownloads> | ||
|
|
||
| <GenerateDocumentationFile>false</GenerateDocumentationFile> | ||
| <DebugType>none</DebugType> | ||
| <GenerateDependencyFile>false</GenerateDependencyFile> | ||
| <LangVersion>preview</LangVersion> | ||
|
|
||
| <!-- NuGet --> | ||
| <IsPackable>true</IsPackable> | ||
| <IsShipping>true</IsShipping> | ||
| <IsSourcePackage>true</IsSourcePackage> | ||
| <PackageId>Microsoft.DotNet.HotReload.Web.Middleware</PackageId> | ||
| <IncludeBuildOutput>false</IncludeBuildOutput> | ||
| <PackageDescription>Package containing web server middleware to support Hot Reload.</PackageDescription> | ||
| <!-- Remove once https://github.com/NuGet/Home/issues/8583 is fixed --> | ||
| <NoWarn>$(NoWarn);NU5128</NoWarn> | ||
| </PropertyGroup> | ||
|
|
||
| <ItemGroup> | ||
| <FrameworkReference Include="Microsoft.AspNetCore.App" /> | ||
| </ItemGroup> | ||
|
|
||
| <ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true'"> | ||
| <!-- Reference 6.0 targeting packs in Source Build --> | ||
| <FrameworkReference Update="Microsoft.AspNetCore.App" TargetingPackVersion="6.0.2" /> | ||
| <FrameworkReference Update="Microsoft.NETCore.App" TargetingPackVersion="6.0.0" /> | ||
| </ItemGroup> | ||
|
|
||
| <!-- Make sure the shared source files do not require any global usings --> | ||
| <ItemGroup> | ||
| <Using Remove="@(Using)" /> | ||
| </ItemGroup> | ||
| </Project> |
15 changes: 15 additions & 0 deletions
15
src/BuiltInTools/Web.Middleware/Microsoft.DotNet.HotReload.Web.Middleware.projitems
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
| <PropertyGroup> | ||
| <MSBuildAllProjects Condition="'$(MSBuildVersion)' == '' Or '$(MSBuildVersion)' < '16.0'">$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects> | ||
| <HasSharedItems>true</HasSharedItems> | ||
| <SharedGUID>9F3A6169-66C9-4244-8FC6-222E4D6F8D29</SharedGUID> | ||
| </PropertyGroup> | ||
| <PropertyGroup Label="Configuration"> | ||
| <Import_RootNamespace>Microsoft.DotNet.HotReload</Import_RootNamespace> | ||
| </PropertyGroup> | ||
| <ItemGroup> | ||
| <Compile Include="$(MSBuildThisFileDirectory)**\*.cs" /> | ||
| <EmbeddedResource Include="$(MSBuildThisFileDirectory)**\*.js" /> | ||
| </ItemGroup> | ||
| </Project> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❤️🔥 I had no idea that a P/Invoke could be a local function.