зеркало из https://github.com/dotnet/razor.git
Set RootNamespace for MS.VS.LanguageServices.Razor (#10653)
All of the types MS.VS.LanguageServices.Razor elide "LanguageServices" from their namespaces. So, each type has `Microsoft.VisualStudio.Razor` its root namespace. These have been kept in sync by pure discipline until this change. This change updates the `<RootNamespace>` for MS.VS.LanguageServices.Razor to not include "LanguageServices". That way, new files in this project will be created with a root namespace of `Microsoft.VisualStudio.Razor`. Normally, changing the `<RootNamespace>` should be a painless process. However, it was blocked due to issues caused by the MS.ANC.Razor.Serialization.Json shared project's embedded string resources. I've gone ahead and sorted that so that updating the `<RootNamespace>` is now possible.
This commit is contained in:
Коммит
cb90af2a06
|
@ -4,9 +4,8 @@
|
||||||
using System;
|
using System;
|
||||||
using Microsoft.AspNetCore.Razor.PooledObjects;
|
using Microsoft.AspNetCore.Razor.PooledObjects;
|
||||||
using Microsoft.CodeAnalysis.Razor.Logging;
|
using Microsoft.CodeAnalysis.Razor.Logging;
|
||||||
using Microsoft.VisualStudio.Razor.Logging;
|
|
||||||
|
|
||||||
namespace Microsoft.VisualStudio.LanguageServices.Razor.Logging;
|
namespace Microsoft.VisualStudio.Razor.Logging;
|
||||||
|
|
||||||
internal sealed partial class ActivityLogLoggerProvider
|
internal sealed partial class ActivityLogLoggerProvider
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,9 +3,8 @@
|
||||||
|
|
||||||
using System.ComponentModel.Composition;
|
using System.ComponentModel.Composition;
|
||||||
using Microsoft.CodeAnalysis.Razor.Logging;
|
using Microsoft.CodeAnalysis.Razor.Logging;
|
||||||
using Microsoft.VisualStudio.Razor.Logging;
|
|
||||||
|
|
||||||
namespace Microsoft.VisualStudio.LanguageServices.Razor.Logging;
|
namespace Microsoft.VisualStudio.Razor.Logging;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An <see cref="ILoggerProvider"/> that logs any warnings or errors to the Visual Studio Activity Log.
|
/// An <see cref="ILoggerProvider"/> that logs any warnings or errors to the Visual Studio Activity Log.
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
<IsShippingPackage>false</IsShippingPackage>
|
<IsShippingPackage>false</IsShippingPackage>
|
||||||
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
|
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
|
||||||
<IsPackable Condition="'$(OS)' != 'Windows_NT'">false</IsPackable>
|
<IsPackable Condition="'$(OS)' != 'Windows_NT'">false</IsPackable>
|
||||||
|
<RootNamespace>Microsoft.VisualStudio.Razor</RootNamespace>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
|
|
@ -7,7 +7,7 @@ using System.Diagnostics.CodeAnalysis;
|
||||||
using Microsoft.AspNetCore.Razor.PooledObjects;
|
using Microsoft.AspNetCore.Razor.PooledObjects;
|
||||||
using Microsoft.Extensions.ObjectPool;
|
using Microsoft.Extensions.ObjectPool;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using SR = Microsoft.AspNetCore.Razor.Serialization.Json.Internal.SR;
|
using SR = Microsoft.AspNetCore.Razor.Serialization.Json.Internal.Strings;
|
||||||
|
|
||||||
namespace Microsoft.AspNetCore.Razor.Serialization.Json;
|
namespace Microsoft.AspNetCore.Razor.Serialization.Json;
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ using System;
|
||||||
using System.Diagnostics.CodeAnalysis;
|
using System.Diagnostics.CodeAnalysis;
|
||||||
using System.Runtime.CompilerServices;
|
using System.Runtime.CompilerServices;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using SR = Microsoft.AspNetCore.Razor.Serialization.Json.Internal.SR;
|
using SR = Microsoft.AspNetCore.Razor.Serialization.Json.Internal.Strings;
|
||||||
|
|
||||||
namespace Microsoft.AspNetCore.Razor.Serialization.Json;
|
namespace Microsoft.AspNetCore.Razor.Serialization.Json;
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="$(MSBuildThisFileDirectory)Internal\Strings.resx">
|
<EmbeddedResource Include="$(MSBuildThisFileDirectory)Internal\Strings.resx">
|
||||||
<GenerateSource>true</GenerateSource>
|
<GenerateSource>true</GenerateSource>
|
||||||
<ClassName>Microsoft.AspNetCore.Razor.Serialization.Json.Internal.SR</ClassName>
|
<Namespace>Microsoft.AspNetCore.Razor.Serialization.Json.Internal</Namespace>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
|
@ -10,7 +10,7 @@ using Microsoft.AspNetCore.Razor.Utilities;
|
||||||
using Microsoft.CodeAnalysis;
|
using Microsoft.CodeAnalysis;
|
||||||
using Microsoft.CodeAnalysis.CSharp;
|
using Microsoft.CodeAnalysis.CSharp;
|
||||||
using static Microsoft.AspNetCore.Razor.Language.RequiredAttributeDescriptor;
|
using static Microsoft.AspNetCore.Razor.Language.RequiredAttributeDescriptor;
|
||||||
using SR = Microsoft.AspNetCore.Razor.Serialization.Json.Internal.SR;
|
using SR = Microsoft.AspNetCore.Razor.Serialization.Json.Internal.Strings;
|
||||||
|
|
||||||
namespace Microsoft.AspNetCore.Razor.Serialization.Json;
|
namespace Microsoft.AspNetCore.Razor.Serialization.Json;
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче