File tree 4 files changed +30
-4033
lines changed
4 files changed +30
-4033
lines changed Original file line number Diff line number Diff line change 48
48
<PackageReference Include =" Microsoft.CSharp" Version =" 4.7.0" />
49
49
</ItemGroup >
50
50
51
- <ItemGroup >
52
- <Compile Update =" Strings.Designer.cs" >
53
- <DesignTime >True</DesignTime >
54
- <AutoGen >True</AutoGen >
55
- <DependentUpon >Strings.resx</DependentUpon >
56
- </Compile >
57
- </ItemGroup >
58
-
51
+ <!--
52
+ This ItemGroup and PropertyGroup block is required for resource generation to work for
53
+ .NET CLI, Visual Studio and VS-Code: https://github.com/dotnet/msbuild/issues/4751
54
+ -->
59
55
<ItemGroup >
60
56
<EmbeddedResource Update =" Strings.resx" >
61
- <Generator >ResXFileCodeGenerator</Generator >
57
+ <!-- Tell Visual Studio that MSBuild will do the generation and run a build if resx file changes. -->
58
+ <Generator >MSBuild:Compile</Generator >
62
59
<LastGenOutput >Strings.Designer.cs</LastGenOutput >
60
+ <StronglyTypedFileName >$(IntermediateOutputPath)\Strings.Designer.cs</StronglyTypedFileName >
61
+ <StronglyTypedLanguage >CSharp</StronglyTypedLanguage >
62
+ <StronglyTypedNamespace >Microsoft.Windows.PowerShell.ScriptAnalyzer</StronglyTypedNamespace >
63
+ <StronglyTypedClassName >Strings</StronglyTypedClassName >
63
64
</EmbeddedResource >
64
65
</ItemGroup >
66
+ <!-- For VS Code/OmniSharp support, ensure that CoreResGen runs before CoreCompile -->
67
+ <PropertyGroup >
68
+ <CoreCompileDependsOn >PrepareResources;$(CompileDependsOn)</CoreCompileDependsOn >
69
+ </PropertyGroup >
70
+
65
71
66
72
<ItemGroup Condition =" '$(TargetFramework)' == 'net6'" >
67
73
<PackageReference Include =" System.Management.Automation" Version =" 7.0.11" />
You can’t perform that action at this time.
0 commit comments