microsoft/slow-cheetah

Works in preview but no trasformation on build netcoreapp3.1

edika99 opened this issue · 2 comments

I'm working on a very simple webhook made on netcoreapp3.1.
I need to transform app.config file depending by the publish profile or the build (debug/release)
When click on apply transform on the app.config it create 45 files: the debug and release files plus 2 files that reflect my publish profiles. My csproj files look like this

 <ItemGroup>
    <Content Remove="app.Debug.config" />
    <Content Remove="app.Release.config" />
    <Content Remove="app.Tethis-Test.config" />
    <Content Remove="app.Tethis.config" />
  </ItemGroup>

  <ItemGroup>
    <None Include="app.Debug.config">
      <IsTransformFile>true</IsTransformFile>
      <DependentUpon>app.config</DependentUpon>
    </None>
    <None Include="app.Release.config">
      <IsTransformFile>true</IsTransformFile>
      <DependentUpon>app.config</DependentUpon>
    </None>
    <None Include="app.Tethis-Test.config">
      <IsTransformFile>true</IsTransformFile>
      <DependentUpon>app.config</DependentUpon>
    </None>
    <None Include="app.Tethis.config">
      <IsTransformFile>true</IsTransformFile>
      <DependentUpon>app.config</DependentUpon>
    </None>
  </ItemGroup>

  <ItemGroup>
    <Content Update="app.config">
      <TransformOnBuild>true</TransformOnBuild>
    </Content>
  </ItemGroup>

When I click on 'Preview transform' the changes are shown correctly, but when I try to build or publish, the app.config in the output does not contains any transformation. Is identical to the original app.config, and no compilation error is thrown.

There is a log where I can check what and where it fails to transform the file?

I had the same issue. I uninstalled SlowCheetah and then installed again and the transform to the app.config file worked as expected when building the app.

Same issue. Any solution?