0

I'm building a console app in visual studio 2022 for Mac. It is a .net program built targeting version 7 of the framework. So far so good. I have my program launching by clicking on the generated console program (the interface is through a web browser).

Since I have some frankly computer-illiterate users, I created a branch fork to add a Windows installer to, and I have been attempting to generate an .app file on macOS so I can make a dmg out of it. I have not had any luck at all doing so.

I even attempted to create a Swift program with nothing more than a launch button with the idea I can simply include my entire program in that as a resource.

I noted though that the generated app file in swift seems to contain a "unix executable file" inside itself, which is exactly what I'm getting out of Visual Studio 2022.

However just replacing that file with mine didn't work. It still shows the launcher program instead of my replacement console program.

What am I doing wrong here? What is the secret sauce for either "a" creating an installable program on macOS from inside Visual Studio (either on Mac or pc) or "b" just turning the created folder and "unix executable file" into an .app?

John Lord
  • 1,941
  • 12
  • 27
  • Do you want a .dmg or an .app? A .app file is just a package containing an Info.plist and your executable, among other things. See [here](https://stackoverflow.com/questions/1596945/building-osx-app-bundle) for how to make one. It's pretty easy if you have Xcode. – Sweeper Jul 16 '23 at 05:13
  • .app. I can build a dmg in the disk software. – John Lord Jul 16 '23 at 13:58
  • Probably the easiest way is to install the macos workload, create a .NET 7.0 macos Project and then remove the UI. – Matt Ward Jul 17 '23 at 10:32
  • that's not necessarily a bad idea. It's not just macos. I don't get an installer on windows either, and I had the same idea for the windows platform. – John Lord Jul 17 '23 at 13:19

0 Answers0