Open unseensenpai opened 2 days ago
Hi, you did a nice research. However, there is the problem of discovering executable. First, the old and new are differently named (mage.exe vs dotnet-mage.exe). I'd say there should be a version 2 of this plugin that ditches the old one and embraces only dotnet way. People with legacy mage can still use version 1.x.
Pushed branch feature/dotnetmage
with prototype based on your work. Would you mind checking it out?
Seems like its working.
I tried on someshitty project cant confirm fully executable but there is a launcher.exe.
About dotnet-mage vs mage.exe, if there is no manifest problem go ahead.
Thanks for update.
What manifest problem did you have in mind?
There is a entryPoint brackets(xml node parent) in exe.manifest for click once operation.
I didnt try that with other type of .net projects (like WPF, WinForms)
Should tested but documentation says it will work:
So if cake mage consumers writes scripts in a correct order that works like in screenshot .net says.
The Correct Order Is:
MageAddLauncher() // Launcher Settings -> Launcher Entry Point (exe or dll) and Target Directory (deployment directory) MageNewApplication() // Application Settings MageSign() // Sign Settings -> Manifest File -> Cert File MageNewDeployment // Deployment Settings -> Manifest File -> Application File MageSign() // Sign Settings -> Application File -> Cert File
And its done.
At the end of the day Cake.Mage would merely invoke dotnet-mage tool, so I guess the addin itself can't deal with these issues?
Mage.exe is updated by dotnet. Dotnet-Mage.exe used on operations. And it requires launcher specification by https://github.com/dotnet/deployment-tools/blob/main/docs/dotnet-mage/README.md#dotnet-mage
Expected Behavior
Launcher should specified to command line builder for deployment operation.
MageSign operation or specific updated operation should -al (add launcher) and -td (target directory) options.
Current Behavior
Cannot create click once because of launcher.exe not exist. Manifest goes with exception inside.
Just imput -al and -td append side.
Possible Solution
I made another method for cake context.
I have created Mage Settings for update.
Now new and update tool can be handle this settings:
NewOrUpdateMageTool.cs
MageRunner.cs should dotnet-mage.exe
Dotnet Tool Resolver should have dotnet-mage.exe path
So cake script can call like this:
Steps to Reproduce (for bugs)
1. 2. 3. 4.
Context
Your Environment