logo

AutoUpdater

main

The NN AutoUpdater is a console application that when started checks config and acts upon it to update the content that it was set to update.
If there is no config, the application asks if you want to set it up.
Intended for Windows. Written in C#.

NejedNiko (c) 2020






Features

  • Auto-updating
  • Installing / Unzipping
  • Version-checking

Planned features

  1. None

How to implement?

(1) First off, you will need to have a version file somewhere installed with your product, your creation, your software. Let's say that an installer leaves this "client.version" (note that the name could be whatever you want, even the extension) file at "C:/temp/" (if you need to link current exe directory, it's made by "./").
"client.version" file then might have whatever information you want to give, but one of the lines must say "version = #.#.#.#" for example "version = 3.2.8.12522", the format of the versioning does not matter. It only has to be numbers divided by dots.
And for each version you need to teach the installer to replace the last one by a new one that should include a new version number.


(2) Now the second thing you will need is a server file. Anywhere accessible on the internet is fine. Let's call this file "server.version", again, it does not matter. The text inside must be as follows (the order does not matter):

version =
{the newest version available, such as 1.2.3.1252}

download =
{\\your ip, or address}\path\installer.exe

install =
{if you want to run an installer (or unpack zip) after download => true, false, 1, 0, yes, no}


(3) Now we are ready to go. Configure the AutoUpdater. You can do that by hand, or follow the instructions from the application (these will appear only if you delete "uconfig.ini").
The application will ask if you want to do that and then ask for two things:
1. path to client version, the currently downloaded one
2. path/url to the server version, where the informations about the newest thing are.


(4) You are ready to go.
But if you still want to edit the config file yourself, the instructions must be as follows (again, the order does not matter):

path =
{path to the "client.server"}

updatefile =
{\\url that leads to "version.server", where the updater can check for information}

downloadurl =
{\\url that leads to the installer -- this is updated automatically when the server is read}

filetype =
{zip, exe, other -- this is updated automatically when the server is read}


All the example files are included with this project. Don't forget to add the AutoUpdater to your primary (you can have many for one thing, what do I know) installer including the uconfig.ini.


Downloads

OpenSource

Not yet available.

Releases

Latest

v1.0.0 | .zip

Older

Nothing in this list yet


License

You can use this under the GNU GENERAL PUBLIC LICENSE.

Included asset - Program icon from https://icons8.com; CC BY-SA 4.0;


Go back
Nikola Nejedlý © 2020-2023
Policy: