diff options
Diffstat (limited to 'src/modules/pacstrap-base/pacstrap-base.cpp')
-rw-r--r-- | src/modules/pacstrap-base/pacstrap-base.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/modules/pacstrap-base/pacstrap-base.cpp b/src/modules/pacstrap-base/pacstrap-base.cpp index 138400160..9641a1a08 100644 --- a/src/modules/pacstrap-base/pacstrap-base.cpp +++ b/src/modules/pacstrap-base/pacstrap-base.cpp @@ -22,12 +22,6 @@ #include "pacstrap-base.h" -/* PacstrapBaseJob private class constants */ - -const QString PacstrapBaseJob::GRUB_THEME_FMT = "sed -i 's|[#]GRUB_THEME=.*|GRUB_THEME=/boot/grub/themes/GNUAxiom/theme.txt|' %1/etc/default/grub" ; -const QString PacstrapBaseJob::GRUB_THEME_ERROR_MSG = "The grub theme installation command has failed." ; - - /* PacstrapBaseJob public instance methods */ PacstrapBaseJob::PacstrapBaseJob(QObject* parent) : PacstrapCppJob(tr(BASE_JOB_NAME) , @@ -40,9 +34,9 @@ PacstrapBaseJob::PacstrapBaseJob(QObject* parent) : PacstrapCppJob(tr(BASE_JOB_N QString PacstrapBaseJob::getPackageList() { - return QListToString(this->localStorage.value(BASE_PACKAGES_KEY ).toList() + - this->localStorage.value(BOOTLODER_PACKAGES_KEY).toList() + - this->localStorage.value(KERNEL_PACKAGES_KEY ).toList() ) ; + return (this->localStorage.value(BASE_PACKAGES_KEY ).toStringList() + + this->localStorage.value(BOOTLODER_PACKAGES_KEY).toStringList() + + this->localStorage.value(KERNEL_PACKAGES_KEY ).toStringList() ).join(' ') ; } @@ -53,20 +47,26 @@ QString PacstrapBaseJob::chrootExec() QString pacstrap_cmd = PACSTRAP_FMT .arg(this->confFile , MOUNTPOINT , packages) ; QString grub_theme_cmd = GRUB_THEME_FMT.arg(MOUNTPOINT) ; - if (!!ExecWithStatus(pacstrap_cmd)) return PACSTRAP_ERROR_MSG ; + if (!!execStatus(pacstrap_cmd , CHROOT_TASK_PROPORTION)) return PACSTRAP_ERROR_MSG ; QString grub_theme_kludge_cmd = QString("echo GRUB_THEME=/boot/grub/themes/GNUAxiom/theme.txt >> %1/etc/default/grub"). arg(MOUNTPOINT) ; printf("[PACSTRAP-BASE]: grub_theme_cmd=%s\n" , grub_theme_cmd.toStdString().c_str()) ; printf("[PACSTRAP-BASE]: grub_theme_cmd IN:\n"); QProcess::execute(QString("/bin/sh -c \"cat %1/etc/default/grub\"").arg(MOUNTPOINT)); - if (!!ExecWithStatus(grub_theme_cmd)) return GRUB_THEME_ERROR_MSG ; + if (!!execStatus(grub_theme_cmd)) return GRUB_THEME_ERROR_MSG ; -if (!!ExecWithStatus(grub_theme_kludge_cmd)) return "grub_theme_kludge_cmd failed" ; +if (!!execStatus(grub_theme_kludge_cmd)) return "grub_theme_kludge_cmd failed" ; printf("[PACSTRAP-BASE]: grub_theme_cmd OUT:\n"); QProcess::execute(QString("/bin/sh -c \"cat %1/etc/default/grub\"").arg(MOUNTPOINT)); return QString("") ; } +/* PacstrapBaseJob private class constants */ + +const QString PacstrapBaseJob::GRUB_THEME_FMT = "sed -i 's|[#]GRUB_THEME=.*|GRUB_THEME=/boot/grub/themes/GNUAxiom/theme.txt|' %1/etc/default/grub" ; +const QString PacstrapBaseJob::GRUB_THEME_ERROR_MSG = "The grub theme installation command has failed." ; + + CALAMARES_PLUGIN_FACTORY_DEFINITION(PacstrapBaseJobFactory , registerPlugin<PacstrapBaseJob>() ;) |