There is no locking on the Log file so conflicting updater processes
may corrupt each others' entries - although in practice this has not
been a problem yet.
Previously the application was restarted from the main install process, which may have
been elevated. The main application must be started from a non-elevated updater/updater.exe
process otherwise the main app will inherit the elevated status from its parent.
* Modify ProcessUtils::runElevated() to return the status code of the process
* Change UpdateInstaller to run the main installation synchronously from the initial
updater process in the case where elevation is not required.
* Remove calls in main.cpp to relaunch the main application after the UI is closed.
* create-packages.rb takes an input directory containing all files as they are laid out in
the installation directory of an application, a JSON file mapping files to packages and
generates the file_list.xml file listing all files in the release along with the
.zip packages containing those files.
* Add single-package-map.json which is the simplest possible package map - putting
all files in a single package.
Per-project/build package maps can be written that separate files into different packages
based on the component they belong to.
This script replaces the autoupdate-setup tool written in C++ in the utilities/autoupdate-setup
directory in the desktop source tree.
Instead of moving the whole <update> section to an embedded <update-v3>
node, just use a different name for the <install> section since older
clients will ignore the new <packages> section.
For older clients:
* The <install> section lists the packages to download. This will exist
in addition to the <packages> section.
* The real <install> section listing the files to install is renamed to
<install-v3>
* Add WIN32 flag to add_executable() so that cmake generates a GUI application
* Add WinMain() entry point which converts the unicode command line arguments to ANSI and then calls the standard main() entry point.
The unit test continues to pass although I am not sure whether
converting command-line args from Unicode to ANSI will cause problems
with filenames passed on the command-line that contain non-ANSI
characters.
std::string::npos is defined as the unsigned type size_t but given a value of -1,
resulting in a warning when trying to compare an unsigned int with a size_t.
Fix this by declaring pos as a size_t.
* Fix ProcessUtils::runAsyncUnix() not returning a value
* Fix UpdateDialogGtk::updateRetryCancel() not returning a value
* Add missing includes in TestUpdaterOptions.cpp
* Fix unsigned/signed int comparisons
This prevents the dialog being closed part-way through update installation,
leaving the user unable to restart the application afterwards by clicking
the 'Finish' button.
UpdaterOptions::parse() will probably not have a need to modify its
arguments but for consistency with the declaration of main() it takes a char*,
so strdup() the strings.
The zlib build system is not integrated with the updater's build
system. Rather than write a small CMakeLists.txt for the build,
this commit just adds a pre-built version of zlib
In the event of a failed update, display the details in a message
box and allow the user to restart the old application once the
update has been reverted.
Details of the problem will also be written to the log file.
This prevents the user closing the dialog whilst the update is in
progress. Once the update has been installed, the user can click
the 'Finish' button to close the dialog and restart the application.