microsoft / Windows-Packaging-Samples

Windows Application Packaging Project Samples.
MIT License
55 stars 37 forks source link

Modifying the artifacts right before packaging #12

Open essoperagma opened 3 years ago

essoperagma commented 3 years ago

Sorry if this isn't the right place for this question.

I have a WPF (Core 3.1) app that I package and publish to Microsoft Store. I want to obfuscate the managed assemblies before they are packaged. How can I achieve this?

I assume this can be done by creating an MSBuild target in the packaging project which triggers right after the WPF project builds and right before the package is created. I can then replace the assemblies with the obfuscated ones. Though I'm not sure before which target I should do this and which folder contains the artifacts to be packaged.

Thanks