Skip to content

ludo6577/ClickOnceEasy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ClickOnceEasy

This project simplify the ClickOnce deployment of all applications type.

Just Configure, Build your app in the Bin folder and Run the script!

That's it! your app and all his updates are now available to your customers!

How to

  1. Put Application's build files in the Bin folder (or configure the Application's Bin folder path in deploy.ps1)
  2. In deploy.ps1: configure the $Version, $AppName, $Publisher and $ServerUrl
  3. Run powershell script: deploy.ps1
  4. then run the ClickOnce launcher named AppName.application (from the Output folder or from the $ServerUrl)
  5. When you want to deploy a new version increment the $Version parameter and re-run the powershell script

Files

  1. deploy.ps1: The deployement script (contains all the parameters and generation's commands)
  2. mage.exe: ClickOnce packager
  3. Tools/Launcher.exe: This exe decompress the Application (first execution) then run it (source code in Tools/src)
  4. icon.ico: The app icon
  5. infos.txt: Generated in deploy.ps1, contains the variables used at generation. Used by the deployed application to check the version number, server address, ...
  6. readme.md

Variables (deploy.ps1)

  1. $Version: Version of the app (need to be incremented so the user can update his version)
  2. $AppName: App name (the one user will see)
  3. $Publisher: Publisher name
  4. $ServerUrl: The url where the app will be published
  5. $BinDirectory: Bin Folder path
  6. $OutputDirectory: Output Folder path
  7. $ToolsDirectory: Tools Folder path
  8. $IconFile: The app icon path

Folders

  1. Bin: contains the binary generated by Unity
  2. Output: Application Bin (after compression), the Launcher.exe, the Manifest and the ClickOnce launcher
  3. Tools: The Launcher.exe and his source code. This exe decompress the Application (first execution) then run it

What it does (deploy.ps1)

  1. The script take the Application's build, compress and copy it in the Output folder
    • Add the Launcher to the Output folder and rename it to $AppName
  2. Generate the manifest
    • TODO: sign the manifest with Authenticode certificate
  3. Generate the installer
    • TODO: sign the installer with Authenticode certificate
  4. Send all the files from Output folder to the $ServerUrl
    • (Application project zip + ClickOnce launcher + renamed launcher + manifest)

What it does (Tools/Launcher.exe)

  1. The Launcher is renamed to fit the application name
  2. When started the Launcher will open the file infos.txt (needed to get the Version number, Server address, Application name, ...)
  3. With the Version Number and the Server Address previously taken from the file info.txt it will check if a newer version is on the server
    • If true launch the setup from the server and exit (the setup will start a new Launcher after the update)
  4. If App.zip exists unzip it
    • Create the desktop icon (warning: when we unistall the app the icon will stay on the desktop)
  5. Then in the current folder it will search for an *.exe (except himself) and start it

Warning: do not call the Unity project the same as $AppName in deploy script (or the Launcher and the Unity's project exes will have the same name)

About

Simplify the ClickOnce deployment of all applications

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published