Reduce File Size

I have a very simple console application written in C#, barely more than a couple megabytes. When I publish my project to a self-contained single-file executable, the file comes out to about 50mb.

What's the easiest way to remove unused dependencies and only publish with what it needs?
Was this page helpful?