diff options
author | Katja Marttila <katja.marttila@qt.io> | 2021-06-15 12:31:29 +0300 |
---|---|---|
committer | Katja Marttila <katja.marttila@qt.io> | 2021-06-16 14:05:09 +0300 |
commit | bd10266110689199ad86d9d314b342f836c5cade (patch) | |
tree | 2935893eda3813da92a82409999fd6eb7ea2ca01 /src/sdk/installerbase.cpp | |
parent | b43f06e569a983ae273560f769ec8e6893515750 (diff) |
Load control script also when using CLI
Task-number: QTIFW-2268
Change-Id: I61e5f7963a55dcdc25aff171523fe078af309785
Reviewed-by: Arttu Tarkiainen <arttu.tarkiainen@qt.io>
Diffstat (limited to 'src/sdk/installerbase.cpp')
-rw-r--r-- | src/sdk/installerbase.cpp | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/src/sdk/installerbase.cpp b/src/sdk/installerbase.cpp index 821eb907b..78da6fb3a 100644 --- a/src/sdk/installerbase.cpp +++ b/src/sdk/installerbase.cpp @@ -71,18 +71,7 @@ int InstallerBase::run() f.setItalic(true); QInstaller::PackageManagerCore::setVirtualComponentsFont(f); } - QString controlScript; - if (m_parser.isSet(CommandLineOptions::scScriptLong)) { - controlScript = m_parser.value(CommandLineOptions::scScriptLong); - if (!QFileInfo(controlScript).exists()) { - qCDebug(QInstaller::lcInstallerInstallLog) << "Script file does not exist."; - return false; - } - } else if (!m_core->settings().controlScript().isEmpty()) { - controlScript = QLatin1String(":/metadata/installer-config/") - + m_core->settings().controlScript(); - } qCDebug(QInstaller::lcInstallerInstallLog) << "Language:" << QLocale().uiLanguages() .value(0, QLatin1String("No UI language set")).toUtf8().constData(); #ifndef IFW_DISABLE_TRANSLATIONS @@ -140,7 +129,7 @@ int InstallerBase::run() //create the wizard GUI TabController controller(nullptr); controller.setManager(m_core); - controller.setControlScript(controlScript); + controller.setControlScript(controlScript()); if (m_core->isInstaller()) controller.setGui(new InstallerGui(m_core)); else |