-
-
Notifications
You must be signed in to change notification settings - Fork 51
Recommended Project Structure
If your project has a self patcher, then it is recommended that you put it and any of its dependencies inside a subdirectory called SPPatcher (determined by PatchParameters.SELF_PATCHER_DIRECTORY) in your application directory. SimplePatchTool will always patch the contents of this directory manually (i.e. it doesn't use the self patcher to patch that directory). This way, you will be able to patch the self patcher itself.
If you are planning to update/launch the main app via a launcher app that can self patch itself, then it is recommended that you put your main app (together with any of its files/dependencies) inside a subdirectory in your application directory. You can name this directory as you like (let's say MainApp). Then, you should add MainApp/
to the ignored paths list of the launcher's patch. This way, neither will the files inside MainApp be included in the launcher's patch nor will it be seen as an obsolete directory while self patching the launcher. Finally, while creating patches for the main app or updating the main app from the launcher, use {APPLICATION_DIRECTORY}\MainApp
as the root path. In conclusion:
- put your main app and all its files inside a subdirectory (e.g. MainApp)
- put the self patcher executable and any of its dependencies inside SPPatcher subdirectory
- create two patches: one for the launcher and one for the main app
- add
MainApp/
to the ignored paths of the launcher's patch - use
{APPLICATION_DIRECTORY}\MainApp
as root path while creating the main app's patch and/or patching the main app - inside your launcher, first check if a new version of the launcher is available. If so, patch it using self patching
- if launcher is up-to-date, check if a new version of the main app is available. If so, patch it without using self patching