Atlanst, I myself understood this.
Here's how:
Create a batch file by copying the following commands and replacing
[PATH] β Absolute path to mage.exe
[path to current version] β published folder with current version
[deploy path] β published path to the folder with the exe file
[New installation address] β installation URL that you want to update
"[PATH] \ mage.exe" -Update "[current version path] \ MyApp.application" -ProviderUrl "[New installation address] /MyApp.application"
"[PATH] \ mage.exe" -Update "[current version path] \ MyApp.application" -AppManifest "[current version path] \ MyApp.exe.manifest"
"[PATH] \ mage.exe" -Sign "[current version path] \ MyApp.application" -CertFile "[path] \ TemporaryKey.pfx" -Password mypassword
"[PATH] \ mage.exe" -Update [deployment path] \ MyApp.application "-ProviderUrl" [New installation address] /MyApp.application "
"[PATH] \ mage.exe" -Update "[deployment path] \ MyApp.application" -AppManifest "[current version path] \ MyApp.exe.manifest"
"[PATH] \ mage.exe" -Sign "[deployment path] \ MyApp.application" -CertFile "[path] \ TemporaryKey.pfx" -Password mypassword
"[deploy path] \ setup.exe" / url = "[New installation address] /"
source share