From 1b44ad3ad9d2352f60315ceea267cabec77317c7 Mon Sep 17 00:00:00 2001 From: simono41 Date: Mon, 3 Sep 2018 01:21:45 +0200 Subject: [PATCH] libre-fixes --- arch-graphical-install-auto | 20 ++++++------- arch-install | 20 ++++++------- make_mksquashfs-auto.sh | 14 ++++----- mirrorlist_libre | 4 +-- mirrorlist_libre-xfce4-openrc | 54 ---------------------------------- xinitrc_libre-xfce4-openrc.txt | 1 - 6 files changed, 29 insertions(+), 84 deletions(-) mode change 100755 => 100644 mirrorlist_libre delete mode 100644 mirrorlist_libre-xfce4-openrc delete mode 100755 xinitrc_libre-xfce4-openrc.txt diff --git a/arch-graphical-install-auto b/arch-graphical-install-auto index e458c1e..a978582 100755 --- a/arch-graphical-install-auto +++ b/arch-graphical-install-auto @@ -333,11 +333,11 @@ chmod 644 /etc/systemd/system/startup.service systemctl enable startup.service # pacman-config -if [ "${version}" == "libre" ]; then +if [ "${version%-*-*}" == "libre" ]; then cp /opt/${repo}/pacman.conf_libre /etc/pacman.conf -elif [ "${version}" == "manjaro" ]; then +elif [ "${version%-*-*}" == "manjaro" ]; then cp /opt/${repo}/pacman.conf_manjaro /etc/pacman.conf -elif [ "${version}" == "pi" ]; then +elif [ "${version%-*-*}" == "pi" ]; then cp /opt/${repo}/pacman.conf_pi /etc/pacman.conf else cp /opt/${repo}/pacman.conf /etc/pacman.conf @@ -351,7 +351,7 @@ if [ -f /var/lib/pacman/db.lck ];then fi # vollinstallation -if [ "$version" != "lite" ] && [ "$packageupdate" != "skip" ]; then +if [ "${version%-*-*}" != "lite" ] && [ "${packageupdate}" != "skip" ]; then standartinstallation fi @@ -361,7 +361,7 @@ echo "Beginne mit dem Konfigurieren des Systems :D" # set desktop echo "set desktop" # -if [ "$version" != "lite" ]; then +if [ "${version%-*-*}" != "lite" ]; then if [ -f "/opt/${repo}/xinitrc_${version}.txt" ]; then cp /opt/${repo}/xinitrc_${version}.txt /etc/X11/xinit/xinitrc else @@ -661,10 +661,10 @@ cp /opt/${repo}/grub_background.png /usr/share/grub/background.png #cp /opt/${repo}/openvpn-reconnect-systemd.sh /usr/lib/systemd/system-sleep/openvpn-reconnect-systemd.sh #chmod +x /usr/lib/systemd/system-sleep/openvpn-reconnect-systemd.sh -if [ "$version" != "manjaro" ]; then +if [ "${version%-*-*}" != "manjaro" ]; then su "$username" -c "aurinstaller "https://aur.archlinux.org/pamac-aur.git"" fi -if [ "$version" != "pi" ] && [ "$version" != "manjaro" ] && [ "$packageupdate" != "skip" ]; then +if [ "${version%-*-*}" != "pi" ] && [ "${version%-*-*}" != "manjaro" ] && [ "$packageupdate" != "skip" ]; then su "$username" -c "aurinstaller "https://aur.archlinux.org/plymouth.git"" su "$username" -c "aurinstaller "https://aur.archlinux.org/plymouth-theme-dark-arch.git"" plymouth-set-default-theme -R dark-arch @@ -750,7 +750,7 @@ fi -if [ "$version" != "lite" ] && [ "$skip" != "skip" ]; then +if [ "${version%-*-*}" != "lite" ] && [ "$skip" != "skip" ]; then ### custom-installer @@ -838,7 +838,7 @@ if [ "$version" != "lite" ] && [ "$skip" != "skip" ]; then cd / - if [ "$version" != "pi" ] && [ "$packageupdate" != "skip" ]; then + if [ "${version%-*-*}" != "pi" ] && [ "$packageupdate" != "skip" ]; then # zusatzsoftware su "$username" -c "aurinstaller "https://aur.archlinux.org/google-chrome.git"" su "$username" -c "aurinstaller spotify" @@ -875,7 +875,7 @@ if [ "$packageupdate" != "skip" ]; then pacman -Syu --needed --noconfirm fi -if [ "${version}" == "libre" ]; then +if [ "${version%-*-*}" == "libre" ]; then mkinitcpio -p linux-libre else mkinitcpio -P -c /etc/mkinitcpio.conf diff --git a/arch-install b/arch-install index e28a882..009f455 100755 --- a/arch-install +++ b/arch-install @@ -69,9 +69,9 @@ function minimalinstallation() { # mirrors # pacman-config - if [ "${version}" == "libre" ]; then + if [ "${version%-*-*}" == "libre" ]; then cp /opt/${repo}/pacman.conf_libre ${mountpoint}/etc/pacman.conf - elif [ "${version}" == "manjaro" ]; then + elif [ "${version%-*-*}" == "manjaro" ]; then cp /opt/${repo}/pacman.conf_manjaro ${mountpoint}/etc/pacman.conf else cp /opt/${repo}/pacman.conf ${mountpoint}/etc/pacman.conf @@ -264,7 +264,7 @@ function cron() { chmod 755 ${mountpoint}/usr/bin/snapshot fi - if [ "${version}" == "manjaro" ]; then + if [ "${version%-*-*}" == "manjaro" ]; then echo "0 * * * * /usr/bin/update-bootloader" >> ${mountpoint}/var/spool/cron/root fi echo "0 20 * * * /usr/bin/update-packages" >> ${mountpoint}/var/spool/cron/root @@ -419,7 +419,7 @@ function installation { parameter="${parameter}usbsecret " fi - if [ "${version}" == "libre" ] || [ "${version}" == "manjaro" ] || [ "${version}" == "lite" ]; then + if [ "${version%-*-*}" == "libre" ] || [ "${version%-*-*}" == "manjaro" ] || [ "${version%-*-*}" == "lite" ]; then echo "überspringe plymouth hook!!!" else if [ "${verschluesselung}" == "y" ]; then @@ -431,7 +431,7 @@ function installation { fi echo "" - if [ "${version}" == "libre" ] || [ "${version}" == "lite" ] || [ "${nvidia}" == "n" ]; then + if [ "${version%-*-*}" == "libre" ] || [ "${version%-*-*}" == "lite" ] || [ "${nvidia}" == "n" ]; then echo "MODULES=\"i915 radeon nouveau ata_generic ata_piix nls_cp437 vfat ext4 btrfs\"" > ${mountpoint}/etc/mkinitcpio.conf echo "HOOKS=\"${parameter}\"" >> ${mountpoint}/etc/mkinitcpio.conf echo "COMPRESSION=\"lz4\"" >> ${mountpoint}/etc/mkinitcpio.conf @@ -798,7 +798,7 @@ function systemdboot() { fi #rootsub=$(btrfs subvolume list /mnt | awk 'NR<0 && NR>2 {print $2}') - if [ "${version}" == "manjaro" ]; then + if [ "${version%-*-*}" == "manjaro" ]; then kernel1="$(echo $(find /boot/ -name "initramfs*.img") | cut -d" " -f1)" linuz1="$(echo $(find /boot/ -name "vmlinuz*") | cut -d" " -f1)" kernel="${kernel1#/*/}" @@ -845,7 +845,7 @@ function systemdboot() { arch-chroot ${mountpoint} efibootmgr -c -d ${device} -p 1 -l \\${linuz} -L "Arch Linux efistub" -u "initrd=/${kernel} root=${tobootdevice} rw ${parameter}nvidia-drm.modeset=1 splash" - if [ "${version}" == "manjaro" ]; then + if [ "${version%-*-*}" == "manjaro" ]; then cp /opt/${repo}/update-bootloader ${mountpoint}/usr/bin/update-bootloader chmod +x ${mountpoint}/usr/bin/update-bootloader fi @@ -1279,7 +1279,7 @@ then if [ "y" == "${windualboot}" ]; then mkinitcpio -c /etc/mkinitcpio.conf -g /boot/initramfs-linux.img else - if [ "${version}" == "libre" ]; then + if [ "${version%-*-*}" == "libre" ]; then arch-chroot ${mountpoint} mkinitcpio -p linux-libre else arch-chroot ${mountpoint} mkinitcpio -P -c /etc/mkinitcpio.conf @@ -1313,7 +1313,7 @@ elif [ "${Partition}" == "bios" ]; then if [ "y" == "${windualboot}" ]; then mkinitcpio -c /etc/mkinitcpio.conf -g /boot/initramfs-linux.img else - if [ "${version}" == "libre" ]; then + if [ "${version%-*-*}" == "libre" ]; then arch-chroot ${mountpoint} mkinitcpio -p linux-libre else arch-chroot ${mountpoint} mkinitcpio -P linux -c /etc/mkinitcpio.conf @@ -1349,7 +1349,7 @@ if [ "y" != "${noinstall}" ] && [ -z "${installationsfehler}" ]; then mkdir -p ${mountpoint}/etc/lightdm/ cp /opt/${repo}/Xsession /opt/${repo}/keys.conf /opt/${repo}/lightdm-gtk-greeter.conf /opt/${repo}/lightdm.conf /opt/${repo}/users.conf ${mountpoint}/etc/lightdm/ if [ "${autostart}" == "y" ]; then - if [ "${version}" == "libre" ] || [ "${version}" == "manjaro" ] || [ "${version}" == "lite" ]; then + if [ "${version%-*-*}" == "libre" ] || [ "${version%-*-*}" == "manjaro" ] || [ "${version%-*-*}" == "lite" ]; then arch-chroot ${mountpoint} systemctl enable lightdm.service else arch-chroot ${mountpoint} systemctl enable lightdm-plymouth.service diff --git a/make_mksquashfs-auto.sh b/make_mksquashfs-auto.sh index 4cb165a..66b0896 100755 --- a/make_mksquashfs-auto.sh +++ b/make_mksquashfs-auto.sh @@ -57,11 +57,11 @@ EOT pacman -Syy fi - if [ "${version}" == "libre" ]; then + if [ "${version%-*-*}" == "libre" ]; then cp pacman.conf_libre /etc/pacman.conf pacman -U --noconfirm --force "https://www.parabola.nu/packages/libre/any/parabola-keyring/download" ./pacstrap -C pacman.conf_libre -c -d -G -M ${work_dir}/${arch}/airootfs $(cat base_libre.txt) - elif [ "${version}" == "manjaro" ]; then + elif [ "${version%-*-*}" == "manjaro" ]; then cp pacman.conf_manjaro /etc/pacman.conf pacman -U --noconfirm --force "https://mirror.philpot.de/manjaro/stable/core/x86_64/manjaro-keyring-20180607-1-any.pkg.tar.xz" ./pacstrap -C pacman.conf_manjaro -c -d -G -M ${work_dir}/${arch}/airootfs $(cat base.txt) @@ -140,11 +140,11 @@ function system() { echo "blacklist nouveau" > ${work_dir}/${arch}/airootfs/etc/modprobe.d/blacklist_nouveau.conf echo "install dell-smbios /bin/false" > ${work_dir}/${arch}/airootfs/etc/modprobe.d/blacklist-dell-smbios.conf - if [ "${version}" != "manjaro" ]; then + if [ "${version%-*-*}" != "manjaro" ]; then plymouth=plymouth fi - if [ "${version}" == "libre" ] || [ "${version}" == "lite" ]; then + if [ "${version%-*-*}" == "libre" ] || [ "${version%-*-*}" == "lite" ]; then echo "MODULES=\"i915 radeon nouveau ata_generic ata_piix nls_cp437 vfat ext4 btrfs\"" > ${work_dir}/${arch}/airootfs/etc/mkinitcpio.conf echo "HOOKS=\"base udev archiso block filesystems keyboard\"" >> ${work_dir}/${arch}/airootfs/etc/mkinitcpio.conf echo "COMPRESSION=\"lz4\"" >> ${work_dir}/${arch}/airootfs/etc/mkinitcpio.conf @@ -224,7 +224,7 @@ function BIOS() { echo "TIMEOUT 300" >> ${work_dir}/iso/${install_dir}/boot/syslinux/syslinux.cfg echo "" >> ${work_dir}/iso/${install_dir}/boot/syslinux/syslinux.cfg - if [ "${version}" != "voll" ] + if [ "${version%-*-*}" != "voll" ] then sed "s|%ISO_LABEL%|${iso_label}|g; @@ -283,7 +283,7 @@ function UEFI() { cp ${work_dir}/iso/${install_dir}/boot/${arch}/vmlinuz ${work_dir}/efiboot/EFI/archiso/vmlinuz.efi cp ${work_dir}/iso/${install_dir}/boot/${arch}/archiso.img ${work_dir}/efiboot/EFI/archiso/archiso.img - #if [ "${version}" != "libre" ]; then + #if [ "${version%-*-*}" != "libre" ]; then #cp ${work_dir}/iso/${install_dir}/boot/${arch}/vmlinuz-lts ${work_dir}/efiboot/EFI/archiso/vmlinuz-lts.efi #cp ${work_dir}/iso/${install_dir}/boot/${arch}/archiso-lts.img ${work_dir}/efiboot/EFI/archiso/archiso-lts.img #fi @@ -348,7 +348,7 @@ function UEFI() { s|%INSTALL_DIR%|${install_dir}|g" $file > ${work_dir}/efiboot/loader/entries/${file##*/} done - if [ "${version}" == "voll" ] + if [ "${version%-*-*}" == "voll" ] then for file in releng/all/archiso-x86_64-usb* diff --git a/mirrorlist_libre b/mirrorlist_libre old mode 100755 new mode 100644 index 74de88e..702e081 --- a/mirrorlist_libre +++ b/mirrorlist_libre @@ -6,14 +6,14 @@ # mirror when possible. Works best specifying it a few times in a # row (404s workaround). # Server = http://redirector.parabola.nu/$repo/os/$arch -#Server = https://redirector.parabola.nu/$repo/os/$arch +Server = https://redirector.parabola.nu/$repo/os/$arch # Location: Reykjavík, Iceland # Responsible: Parabola Project # Note: Not really a mirror, automatically redirects you to a Parabola # mirror that has the file you are looking for. # Server = http://repomirror.parabola.nu/$repo/os/$arch -#Server = https://repomirror.parabola.nu/$repo/os/$arch +Server = https://repomirror.parabola.nu/$repo/os/$arch # Location: Falkenstein, Germany # Server = http://mirror.grapentin.org/parabola/$repo/os/$arch diff --git a/mirrorlist_libre-xfce4-openrc b/mirrorlist_libre-xfce4-openrc deleted file mode 100644 index 702e081..0000000 --- a/mirrorlist_libre-xfce4-openrc +++ /dev/null @@ -1,54 +0,0 @@ -# Parabola GNU/Linux-libre - Last Updated: Wed Dec 20 02:59:35 GMT 2017 - -# Location: London, UK -# Responsible: Parabola Project -# Note: Not really a mirror, automatically redirects you to an Arch -# mirror when possible. Works best specifying it a few times in a -# row (404s workaround). -# Server = http://redirector.parabola.nu/$repo/os/$arch -Server = https://redirector.parabola.nu/$repo/os/$arch - -# Location: Reykjavík, Iceland -# Responsible: Parabola Project -# Note: Not really a mirror, automatically redirects you to a Parabola -# mirror that has the file you are looking for. -# Server = http://repomirror.parabola.nu/$repo/os/$arch -Server = https://repomirror.parabola.nu/$repo/os/$arch - -# Location: Falkenstein, Germany -# Server = http://mirror.grapentin.org/parabola/$repo/os/$arch -Server = https://mirror.grapentin.org/parabola/$repo/os/$arch - -# Location: Volendam, Netherlands -Server = https://jeweet.net/repo/parabola/$repo/os/$arch - -# Location: Amsterdam, Netherlands -# Note: Not really a mirror, but a high-speed 10GiB cache for -# mirror.yandex.ru/mirrors/parabola -# Server = http://parabola.isacdaavid.info:8080/$repo/os/$arch -Server = https://parabola.isacdaavid.info:8081/$repo/os/$arch - -# Location: Moscow, Russian Federation -# Server = http://mirror.yandex.ru/mirrors/parabola/$repo/os/$arch -Server = https://mirror.yandex.ru/mirrors/parabola/$repo/os/$arch - -# Location: Ho Chi Minh City, Vietnam -# Server = http://mirror.freedif.org/Parabola/$repo/os/$arch -Server = https://mirror.freedif.org/Parabola/$repo/os/$arch - -# Location: Los Angeles, CA, USA -# Note: Also visit http://alfplayer.com/ for its SNAPSHOTS ARCHIVE -Server = http://alfplayer.com/parabola/$repo/os/$arch - -# Location: Boston, MA, USA -Server = http://mirror.fsf.org/parabola/$repo/os/$arch - -# Location: Austin, TX, USA -# Server = http://parabola.serverpit.com/ -Server = https://parabola.serverpit.com/ - -# Location: Reykjavík, Iceland -# Responsible: Parabola Project -# Note: Currently pointing to repomirror.parabola.nu -# Server = http://repo.parabola.nu/$repo/os/$arch -Server = https://repo.parabola.nu/$repo/os/$arch diff --git a/xinitrc_libre-xfce4-openrc.txt b/xinitrc_libre-xfce4-openrc.txt deleted file mode 100755 index ff8a1e5..0000000 --- a/xinitrc_libre-xfce4-openrc.txt +++ /dev/null @@ -1 +0,0 @@ -exec startxfce4