log wm_de install

merge-requests/273/head
Bernhard Landauer 7 years ago
parent b459445d70
commit 86f8c836b2

@ -38,7 +38,8 @@ install_de_wm() {
if [[ $(cat ${PACKAGES}) != "" ]]; then
clear
sed -i 's/+\|\"//g' ${PACKAGES}
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
LOG "install_de_wm selected: ${PACKAGES}"
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
check_for_error
# Clear the packages file for installation of "common" packages
@ -66,7 +67,7 @@ install_de_wm() {
# If at least one package, install.
if [[ $(cat ${PACKAGES}) != "" ]]; then
clear
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
check_for_error
fi
fi
@ -82,6 +83,7 @@ install_manjaro_de_wm() {
# If something has been selected, install
if [[ $(cat /tmp/.desktop) != "" ]]; then
LOG "manjaro_de_wm selected: $(cat /tmp/.desktop)"
clear
# Source the iso-profile
profile=$(echo $PROFILES/*/$(cat /tmp/.desktop)/profile.conf)
@ -170,12 +172,14 @@ install_manjaro_de_wm() {
mv /tmp/.tmp /tmp/.edition
# remove zsh
sed -i '/^zsh$/d' /tmp/.edition
LOG "install pkgs: $(cat /tmp/.desktop)"
# basestrap the parsed package list to the new root
basestrap -i ${MOUNTPOINT} $(cat /tmp/.edition /usr/share/manjaro-architect/package-lists/input-drivers | sort | uniq)
# copy the profile overlay to the new root
echo "Copying overlay files to the new root"
cp -r "$overlay"* ${MOUNTPOINT} 2>/tmp/.errlog
cp -r "$overlay"* ${MOUNTPOINT} 2>$ERR
check_for_error
# Enable services in the chosen profile
@ -192,13 +196,13 @@ install_manjaro_de_wm() {
# enable display manager for openrc
if [[ "$(cat /tmp/.display-manager)" == sddm ]]; then
sed -i "s/$(grep "DISPLAYMANAGER=" /mnt/etc/conf.d/xdm)/DISPLAYMANAGER=\"sddm\"/g" /mnt/etc/conf.d/xdm
arch_chroot "rc-update add xdm default || true" 2>/tmp/.errlog
arch_chroot "rc-update add xdm default || true" 2>$ERR
check_for_error
set_sddm_ck
elif [[ "$(cat /tmp/.display-manager)" == lightdm ]]; then
set_lightdm_greeter
sed -i "s/$(grep "DISPLAYMANAGER=" /mnt/etc/conf.d/xdm)/DISPLAYMANAGER=\"lightdm\"/g" /mnt/etc/conf.d/xdm
arch_chroot "rc-update add xdm default" 2>/tmp/.errlog
arch_chroot "rc-update add xdm default" 2>$ERR
check_for_error
else
echo "no display manager was installed"
@ -214,13 +218,13 @@ install_manjaro_de_wm() {
# enable display manager for systemd
if [[ "$(cat /tmp/.display-manager)" == lightdm ]]; then
set_lightdm_greeter
arch_chroot "systemctl enable lightdm" 2>/tmp/.errlog
arch_chroot "systemctl enable lightdm" 2>$ERR
check_for_error
elif [[ "$(cat /tmp/.display-manager)" == sddm ]]; then
arch_chroot "systemctl enable sddm" 2>/tmp/.errlog
arch_chroot "systemctl enable sddm" 2>$ERR
check_for_error
elif [[ "$(cat /tmp/.display-manager)" == gdm ]]; then
arch_chroot "systemctl enable gdm" 2>/tmp/.errlog
arch_chroot "systemctl enable gdm" 2>$ERR
check_for_error
else
echo "no display manager was installed"
@ -263,7 +267,7 @@ install_manjaro_de_wm() {
# If at least one package, install.
if [[ $(cat ${PACKAGES}) != "" ]]; then
clear
basestrap -i ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap -i ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
check_for_error
fi
fi
@ -313,13 +317,13 @@ install_dm() {
enable_dm() {
if [[ -e /tmp/.openrc ]]; then
sed -i "s/$(grep "DISPLAYMANAGER=" /mnt/etc/conf.d/xdm)/DISPLAYMANAGER=\"$(cat ${PACKAGES})\"/g" /mnt/etc/conf.d/xdm
arch_chroot "rc-update add xdm default" 2>/tmp/.errlog
arch_chroot "rc-update add xdm default" 2>$ERR
check_for_error
DM=$(cat ${PACKAGES})
DM_ENABLED=1
else
# enable display manager for systemd
arch_chroot "systemctl enable $(cat ${PACKAGES})" 2>/tmp/.errlog
arch_chroot "systemctl enable $(cat ${PACKAGES})" 2>$ERR
check_for_error
DM=$(cat ${PACKAGES})
DM_ENABLED=1
@ -357,7 +361,7 @@ install_dm() {
if [[ $DM_ENABLED -eq 0 ]]; then
# Where lightdm selected, add gtk greeter package
sed -i 's/lightdm/lightdm lightdm-gtk-greeter/' ${PACKAGES}
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
# Where lightdm selected, now remove the greeter package
sed -i 's/lightdm-gtk-greeter//' ${PACKAGES}
@ -402,9 +406,9 @@ install_nm() {
enable_nm() {
# Add openrc support. If openrcbase was installed, the file /tmp/.openrc should exist.
if [[ $(cat ${PACKAGES}) == "NetworkManager" ]]; then
arch_chroot "systemctl enable NetworkManager.service && systemctl enable NetworkManager-dispatcher.service" >/tmp/.symlink 2>/tmp/.errlog
arch_chroot "systemctl enable NetworkManager.service && systemctl enable NetworkManager-dispatcher.service" >/tmp/.symlink 2>$ERR
else
arch_chroot "systemctl enable $(cat ${PACKAGES})" 2>/tmp/.errlog
arch_chroot "systemctl enable $(cat ${PACKAGES})" 2>$ERR
fi
check_for_error
@ -442,7 +446,7 @@ install_nm() {
if [[ $NM_ENABLED -eq 0 ]]; then
# Where networkmanager selected, add network-manager-applet
sed -i 's/NetworkManager/networkmanager network-manager-applet/g' ${PACKAGES}
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
# Where networkmanager selected, now remove network-manager-applet
sed -i 's/networkmanager network-manager-applet/NetworkManager/g' ${PACKAGES}
@ -487,7 +491,7 @@ install_multimedia_menu() {
clear
# If at least one package, install.
if [[ $(cat ${PACKAGES}) != "" ]]; then
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
check_for_error
fi
}
@ -508,7 +512,7 @@ install_multimedia_menu() {
clear
# If at least one package, install.
if [[ $(cat ${PACKAGES}) != "" ]]; then
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
check_for_error
fi
}
@ -523,7 +527,7 @@ install_multimedia_menu() {
if [[ $(cat ${PACKAGES}) == "hen poem" ]]; then
DIALOG " \"My Sweet Buckies\" by Atiya & Carl " --msgbox "\nMy Sweet Buckies,\nYou are the sweetest Buckies that ever did \"buck\",\nLily, Rosie, Trumpet, and Flute,\nMy love for you all is absolute!\n\nThey buck: \"We love our treats, we are the Booyakka sisters,\"\n\"Sometimes we squabble and give each other comb-twisters,\"\n\"And in our garden we love to sunbathe, forage, hop and jump,\"\n\"We love our freedom far, far away from that factory farm dump,\"\n\n\"For so long we were trapped in cramped prisons full of disease,\"\n\"No sunlight, no fresh air, no one who cared for even our basic needs,\"\n\"We suffered in fear, pain, and misery for such a long time,\"\n\"But now we are so happy, we wanted to tell you in this rhyme!\"\n\n" 0 0
else
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>/tmp/.errlog
basestrap ${MOUNTPOINT} $(cat ${PACKAGES}) 2>$ERR
check_for_error
fi
fi

@ -151,7 +151,7 @@ id_system() {
check_for_error() {
if [[ $? -eq 1 ]] && [[ $(cat ${ERR} | grep -i "error") != "" ]]; then
DIALOG " $_ErrTitle " --msgbox "$(cat ${ERR})" 0 0
LOG "ERROR : $(cat ${ERR})"
LOG "ERROR : $(cat ${ERR})"
echo "" > $ERR
main_menu_online

Loading…
Cancel
Save