Skip to content

Commit

Permalink
Add ocis release channel
Browse files Browse the repository at this point in the history
Fixes: #11742
  • Loading branch information
TheOneRing committed Jul 25, 2024
1 parent 3522a8d commit 0a927fa
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 15 deletions.
7 changes: 7 additions & 0 deletions changelog/unreleased/11742
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Change: New update channel for ownCloud infinite scale

The release series 6 is a long term release.
As version 7 will drop the support for ownCloud 10, users will either have to select the ownCloud infinite scale update channel in the about dialog or manually install a newer release.
This change only affects the unbranded version.

https://github.com/owncloud/client/issues/11742
38 changes: 23 additions & 15 deletions src/gui/aboutdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@
#endif
#endif

namespace {
bool isTestPilotCloudTheme()
{
return OCC::Theme::instance()->appName() != QLatin1String("testpilotcloud");
}
}

namespace OCC {

Expand Down Expand Up @@ -63,8 +69,8 @@ void AboutDialog::openBrowserFromUrl(const QUrl &s)
void AboutDialog::setupUpdaterWidget()
{
#ifdef WITH_AUTO_UPDATER
// Only our standard brandings currently support beta channel
if (Theme::instance()->appName() != QLatin1String("testpilotcloud")) {
// non standard update channels are only supported by the vanilla theme and the testpilotcloud theme
if (!Resources::isVanillaTheme() && isTestPilotCloudTheme()) {
if (Utility::isMac()) {
// Because we don't have any statusString from the SparkleUpdater anyway we can hide the whole thing
ui->updaterWidget->hide();
Expand All @@ -78,8 +84,11 @@ void AboutDialog::setupUpdaterWidget()
}
// we want to attach the known english identifiers which are also used within the configuration file as user data inside the data model
// that way, when we intend to reset to the original selection when the dialog, we can look up the config file's stored value in the data model
ui->updateChannel->addItem(tr("stable"), QStringLiteral("stable"));
ui->updateChannel->addItem(tr("beta"), QStringLiteral("beta"));
ui->updateChannel->addItem(tr("ownCloud 10 LTS"), QStringLiteral("stable"));
ui->updateChannel->addItem(tr("ownCloud Infinite Scale stable"), QStringLiteral("ocis"));
if (!Resources::isVanillaTheme()) {
ui->updateChannel->addItem(tr("beta"), QStringLiteral("beta"));
}

if (!ConfigFile().skipUpdateCheck() && Updater::instance()) {
// Channel selection
Expand Down Expand Up @@ -151,17 +160,16 @@ void AboutDialog::slotUpdateChannelChanged([[maybe_unused]] int index)
}

auto msgBox = new QMessageBox(QMessageBox::Warning, tr("Change update channel?"),
tr("The update channel determines which client updates will be offered "
"for installation. The \"stable\" channel contains only upgrades that "
"are considered reliable, while the versions in the \"beta\" channel "
"may contain newer features and bugfixes, but have not yet been tested "
"thoroughly."
"\n\n"
"Note that this selects only what pool upgrades are taken from, and that "
"there are no downgrades: So going back from the beta channel to "
"the stable channel usually cannot be done immediately and means waiting "
"for a stable version that is newer than the currently installed beta "
"version."),
tr("<html>The update channel determines which client updates will be offered for installation.<ul>"
"<li>\"ownCloud 10 LTS\" contains only upgrades that are considered reliable.</li>"
"<li>\"ownCloud Infinite Scale stable\" contains only upgrades that are considered reliable but removes support for \"ownCloud 10\"</li>"
"%1"
"</ul>"
"<br>Note that this selects only what pool upgrades are taken from, and that there are no downgrades: So going back from the beta channel to the "
"stable channel usually cannot be done immediately and means waiting for a stable version that is newer than the currently installed beta "
"version.</html>")
.arg(isTestPilotCloudTheme() ? tr("<li>\"beta\" may contain newer features and bugfixes, but have not yet been tested thoroughly.</li>")
: QString()),
QMessageBox::NoButton, this);
auto acceptButton = msgBox->addButton(tr("Change update channel"), QMessageBox::AcceptRole);
msgBox->addButton(tr("Cancel"), QMessageBox::RejectRole);
Expand Down

0 comments on commit 0a927fa

Please sign in to comment.