Skip to content

Cleaning project doesn't clean publish folders #9268

@DoctorKrolic

Description

@DoctorKrolic

WiX Version

6.0.2

.NET or MSBuild or Visual Studio Version

.NET SDK 10.0.201

HeatWave Version

1.0.6

Repro Steps

  • Have a Wix project that references a target project with Publish="true" option in a .wixproj file:
<Project Sdk="WixToolset.Sdk/6.0.2">

  ...

  <ItemGroup>
    <ProjectReference Include="path\to\target\app.csproj" Publish="true" />
  </ItemGroup>

  ...

</Project>
  • Buind the project. As expected, app has been published to the path\to\installer\project\obj\$(Platform)\$(Configuration)\publish\ProjectName directory
  • Run dotnet clean on the project or right click on project is VS and run 'Clean' context menu action

Repro Repo

No response

Actual Result

The path\to\installer\project\obj\$(Platform)\$(Configuration)\publish\ProjectName (or the whole publish folder) in not cleaned. In practice this may lead to unexpected files being bundled into an installer. For example, in my app I had a dependency. Then I refactored my code to avoid it. Then cleaned solution/installer project and rebuilt the installer. Since the previous dependency dll is still in the publish\ProjectName folder, it gets bundled into an installer despite being no longer needed

Expected Result

Cleaning project deletes all content of path\to\installer\project\obj\$(Platform)\$(Configuration)\publish folder to clean all previous publish results

Acknowledgements

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions