If I add a new resx file to my properties folder in my new dotnetstandard 2.0 SDK project from VS2017 I see
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<EmbeddedResource Remove="Properties\foo.resx" />
</ItemGroup>
<ItemGroup>
<Compile Update="Properties\MyWords.Designer.cs">
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
<DependentUpon>MyWords.resx</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Update="Properties\MyWords.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>MyWords.Designer.cs</LastGenOutput>
</EmbeddedResource>
</ItemGroup>
</Project>
However I'd prefer to have this handled the same way normal cs files are handled. The project is empty and the filesystem is searched. What is the globby way to achieve the above so that when I add new files they don't end up explicity declared.
My first attempt is
<ItemGroup>
<Compile Update="Properties\**\*.designer.cs">
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
<DependentUpon>Properties\%(Filename).resx</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Update="Properties\**\*.resx">
<Generator>ResXFileCodeGenerator</Generator>
</EmbeddedResource>
</ItemGroup>
but this won't work because
Properties\%(Filename).resx
expands to
Properties\Foo.designer.resx
instead of
Properties\Foo.resx