summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-08-20 19:42:43 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-08-20 21:52:40 +0200
commit22aaa9be2ef05358f672ce8fc9f6978664741e7f (patch)
tree6693145618061ba247d90f1c8ff5e57284a38a0a /desktop
parent2d29dae57ed151be7244aa0a1e2317b30a4c928d (diff)
updater: move the update channel info from the config to versionrc
Change-Id: Id19578a889de51cacac869d7ec681c5c18c40cf9 Reviewed-on: https://gerrit.libreoffice.org/41365 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'desktop')
-rw-r--r--desktop/source/app/updater.cxx10
-rw-r--r--desktop/source/app/updater.hxx1
2 files changed, 10 insertions, 1 deletions
diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx
index 4049b0ab3472..86e7a473783b 100644
--- a/desktop/source/app/updater.cxx
+++ b/desktop/source/app/updater.cxx
@@ -687,7 +687,7 @@ void update_checker()
OUString aBuildTarget = "${_OS}_${_ARCH}";
rtl::Bootstrap::expandMacros(aBuildTarget);
- OUString aChannel = officecfg::Office::Update::Update::UpdateChannel::get();
+ OUString aChannel = Updater::getUpdateChannel();
static const char* pUpdateChannelEnv = std::getenv("LIBO_UPDATER_CHANNEL");
if (pUpdateChannelEnv)
{
@@ -835,6 +835,14 @@ OUString Updater::getBuildID()
return aBuildID;
}
+OUString Updater::getUpdateChannel()
+{
+ OUString aUpdateChannel("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" SAL_CONFIGFILE("version") ":UpdateChannel}");
+ rtl::Bootstrap::expandMacros(aUpdateChannel);
+
+ return aUpdateChannel;
+}
+
void Updater::removeUpdateFiles()
{
Updater::log("Removing: " + getUpdateFileURL());
diff --git a/desktop/source/app/updater.hxx b/desktop/source/app/updater.hxx
index 937728dd70bc..a029832d17d3 100644
--- a/desktop/source/app/updater.hxx
+++ b/desktop/source/app/updater.hxx
@@ -29,6 +29,7 @@ public:
static OUString getInstallationPath();
static OUString getBuildID();
+ static OUString getUpdateChannel();
static void log(const OUString& rMessage);
static void log(const OString& rMessage);