From 60d06bf0b851a34a0f09be2436e2b569646030c4 Mon Sep 17 00:00:00 2001 From: Amy Date: Wed, 10 Nov 2021 17:33:48 +0100 Subject: [PATCH] thanks jnats for telling me subvols arent needed --- citrine.internal.sh | 161 ++++++++++++++------------------------------ 1 file changed, 51 insertions(+), 110 deletions(-) diff --git a/citrine.internal.sh b/citrine.internal.sh index 4995a1a..2c4d569 100755 --- a/citrine.internal.sh +++ b/citrine.internal.sh @@ -136,32 +136,12 @@ if [[ "$MANUAL" == "no" ]]; then mkfs.vfat ${DISK}p1 mkfs.btrfs -f ${DISK}p2 mount ${DISK}p2 /mnt - cd /mnt - btrfs subvolume create @ - btrfs subvolume create @home - btrfs subvolume create @var - cd / - umount /mnt - mount -o noatime,compress=zstd,subvol=@ ${DISK}p2 /mnt - mkdir -p /mnt/{home,var,boot/efi} - mount -o noatime,compress=zstd,subvol=@home ${DISK}p2 /mnt/home - mount -o noatime,compress=zstd,subvol=@var ${DISK}p2 /mnt/var + mkdir -p /mnt/boot/efi mount ${DISK}p1 /mnt/boot/efi else inf "Initializing ${DISK} as NVME MBR" mkfs.btrfs -f ${DISK}p1 mount ${DISK}p1 /mnt - cd /mnt - btrfs subvolume create @ - btrfs subvolume create @home - btrfs subvolume create @var - cd / - umount /mnt - mount -o noatime,compress=zstd,subvol=@ ${DISK}p1 /mnt - mkdir -p /mnt/{home,var} - mount -o noatime,compress=zstd,subvol=@home ${DISK}p1 /mnt/home - mount -o noatime,compress=zstd,subvol=@var ${DISK}p1 /mnt/var - mount ${DISK}p1 /mnt fi else if [[ "$EFI" == "yes" ]]; then @@ -169,16 +149,7 @@ if [[ "$MANUAL" == "no" ]]; then mkfs.vfat -F32 ${DISK}1 mkfs.btrfs -f ${DISK}2 mount ${DISK}2 /mnt - cd /mnt - btrfs subvolume create @ - btrfs subvolume create @home - btrfs subvolume create @var - cd / - umount /mnt - mount -o noatime,compress=zstd,subvol=@ ${DISK}2 /mnt - mkdir -p /mnt/{home,var,boot/efi} - mount -o noatime,compress=zstd,subvol=@home ${DISK}2 /mnt/home - mount -o noatime,compress=zstd,subvol=@var ${DISK}2 /mnt/var + mkdir -p /mnt/boot/efi mount ${DISK}1 /mnt/boot/efi else inf "Initializing ${DISK} as MBR" @@ -377,87 +348,57 @@ clear arch-chroot /mnt pacman -Sy --quiet --noconfirm - -#if [[ "$DEP" == "0" ]]; then - #inf "--- Desktop Environments ---" - #inf "- GNOME" - #inf "- KDE" - #inf "- Xfce" - #inf "- Budgie" - #inf "Please enter exactly as shown." - #prompt "" - #echo "DE=$response" - #DE="$response" - #DM="" - #case "$DE" in - #"Budgie" | "budgie") - # arch-chroot /mnt pacman -S --quiet --noconfirm budgie-desktop gnome - # DM="gdm" - # ;; - #"Gnome" | "GNOME" | "gnome") - # arch-chroot /mnt pacman -S --quiet --noconfirm gnome gnome-extra chrome-gnome-shell - # DM="gdm" - # ;; - #"KDE" | "Kde" | "kde") - # arch-chroot /mnt pacman -S --quiet --noconfirm plasma kde-applications sddm - # DM="sddm" - #"Xfce" | "xfce") - # arch-chroot /mnt pacman -S --quiet --noconfirm xfce4 xfce4-goodies - # DM="sddm" - # ;; - #esac - while [[ "$DE" == "" ]]; do - menu=$(dialog --title "Citrine" --menu "Select the Desktop Environment you want to install" 12 100 4 "Official" "Our pre-themed desktop environments" "Third Party (supported)" "Third party Desktop Environments that are supported" "Third Party (unsupported)" "Third Party Desktop Environments that aren't supported" "None/DIY" "Install no de from this list" --stdout) - if [[ "$menu" == "Official" ]]; then - DE=$(dialog --title "Citrine" --menu "Please choose the DE you want to install" 12 100 2 "Onyx" "Our custom Desktop Environment based on XFCE" "Onyx tiling" "Our custom Desktop Environment based on xfce but with i3 as the wm" --stdout) - elif [[ "$menu" == "Third Party (supported)" ]]; then - DE=$(dialog --title "Citrine" --menu "Please choose the DE you want to install" 12 100 5 "Gnome" "The Gnome desktop environment" "KDE" "The KDE desktop environment" "Xfce" "The xfce desktop environment" "budgie" "The budgie desktop environment" "Mate" "The Mate desktop environment" --stdout) - elif [[ "$menu" == "Third Party (unsupported)" ]]; then - DE=$(dialog --title "Citrine" --menu "Please choose the DE you want to install" 12 100 2 "Pantheon" "The Pantheon desktop environment from elementaryos" "Enlightenment" "A very DIY desktop environment, refer to archwiki" --stdout) - elif [[ "$menu" == "None/DIY" ]]; then - yesno "Are you sure that you dont want to install any DE?" - if [[ "$yn" == "0" ]]; then - DE="none" - DM="none" - else - DE="" - fi +while [[ "$DE" == "" ]]; do + menu=$(dialog --title "Citrine" --menu "Select the Desktop Environment you want to install" 12 100 4 "Official" "Our pre-themed desktop environments" "Third Party (supported)" "Third party Desktop Environments that are supported" "Third Party (unsupported)" "Third Party Desktop Environments that aren't supported" "None/DIY" "Install no de from this list" --stdout) + if [[ "$menu" == "Official" ]]; then + DE=$(dialog --title "Citrine" --menu "Please choose the DE you want to install" 12 100 2 "Onyx" "Our custom Desktop Environment based on XFCE" "Onyx tiling" "Our custom Desktop Environment based on xfce but with i3 as the wm" --stdout) + elif [[ "$menu" == "Third Party (supported)" ]]; then + DE=$(dialog --title "Citrine" --menu "Please choose the DE you want to install" 12 100 5 "Gnome" "The Gnome desktop environment" "KDE" "The KDE desktop environment" "Xfce" "The xfce desktop environment" "budgie" "The budgie desktop environment" "Mate" "The Mate desktop environment" --stdout) + elif [[ "$menu" == "Third Party (unsupported)" ]]; then + DE=$(dialog --title "Citrine" --menu "Please choose the DE you want to install" 12 100 2 "Pantheon" "The Pantheon desktop environment from elementaryos" "Enlightenment" "A very DIY desktop environment, refer to archwiki" --stdout) + elif [[ "$menu" == "None/DIY" ]]; then + yesno "Are you sure that you dont want to install any DE?" + if [[ "$yn" == "0" ]]; then + DE="none" + DM="none" + else + DE="" fi - done - if [[ "$DE" == "Onyx" ]]; then - #arch-chroot /mnt pacman -S --quiet --noconfirm onyx - #DM="lightdm" - dumptitle="Desktop Environment" - dump "Onyx is not supported yet, please choose another DE" - DE="" - elif [[ "$DE" == "Onyx tiling" ]]; then - #arch-chroot /mnt pacman -S --quiet --noconfirm onyx-tiling - #DM="lightdm" - dumptitle="Desktop Environment" - dump "Onyx is not supported yet, please choose another DE" - DE="" - elif [[ "$DE" == "Gnome" ]]; then - arch-chroot /mnt pacman -S --quiet --noconfirm gnome gnome-extra chrome-gnome-shell - DM="gdm" - elif [[ "$DE" == "KDE" ]]; then - arch-chroot /mnt pacman -S --quiet --noconfirm plasma kde-applications sddm - DM="sddm" - elif [[ "$DE" == "budgie" ]]; then - arch-chroot /mnt pacman -S --quiet --noconfirm budgie-desktop gnome - DM="gdm" - elif [[ "$DE" == "Mate" ]]; then - arch-chroot /mnt pacman -S --quiet --noconfirm mate mate-extra mate-applet-dock mate-applet-streamer - DM="gdm" - elif [[ "$DE" == "Pantheon" ]]; then - arch-chroot /mnt su - ${UN} -c "ame -S gala wingpanel pantheon-applications-menu plank pantheon-geoclue2-agent pantheon-polkit-agent pantheon-print pantheon-settings-daemon lightdm lightdm-pantheon-greeter pantheon-default-settings elementary-icon-theme elementary-wallpapers gtk-theme-elementary ttf-droid ttf-opensans ttf-roboto sound-theme-elementary capnet-assist epiphany pantheon-calculator pantheon-calendar pantheon-camera pantheon-code pantheon-files pantheon-mail pantheon-music pantheon-photos pantheon-screencast pantheon-shortcut-overlay pantheon-terminal pantheon-videos simple-scan pantheon-session pantheon switchboard-plugin-desktop" > /mnt/pantheon-packages.txt - DM="lightdm" - elif [[ "$DE" == "Enlightenment" ]]; then - arch-chroot /mnt pacman -S --quiet --noconfirm enlightenment terminology - elif [[ "$DE" == "Xfce" ]]; then - arch-chroot /mnt pacman -S --quiet --noconfirm xfce4 xfce4-goodies - DM="lightdm" fi -#fi +done +if [[ "$DE" == "Onyx" ]]; then + #arch-chroot /mnt pacman -S --quiet --noconfirm onyx + #DM="lightdm" + dumptitle="Desktop Environment" + dump "Onyx is not supported yet, please choose another DE" + DE="" +elif [[ "$DE" == "Onyx tiling" ]]; then + #arch-chroot /mnt pacman -S --quiet --noconfirm onyx-tiling + #DM="lightdm" + dumptitle="Desktop Environment" + dump "Onyx is not supported yet, please choose another DE" + DE="" +elif [[ "$DE" == "Gnome" ]]; then + arch-chroot /mnt pacman -S --quiet --noconfirm gnome gnome-extra chrome-gnome-shell + DM="gdm" +elif [[ "$DE" == "KDE" ]]; then + arch-chroot /mnt pacman -S --quiet --noconfirm plasma kde-applications sddm + DM="sddm" +elif [[ "$DE" == "budgie" ]]; then + arch-chroot /mnt pacman -S --quiet --noconfirm budgie-desktop gnome + DM="gdm" +elif [[ "$DE" == "Mate" ]]; then + arch-chroot /mnt pacman -S --quiet --noconfirm mate mate-extra mate-applet-dock mate-applet-streamer + DM="gdm" +elif [[ "$DE" == "Pantheon" ]]; then + arch-chroot /mnt su - ${UN} -c "ame -S gala wingpanel pantheon-applications-menu plank pantheon-geoclue2-agent pantheon-polkit-agent pantheon-print pantheon-settings-daemon lightdm lightdm-pantheon-greeter pantheon-default-settings elementary-icon-theme elementary-wallpapers gtk-theme-elementary ttf-droid ttf-opensans ttf-roboto sound-theme-elementary capnet-assist epiphany pantheon-calculator pantheon-calendar pantheon-camera pantheon-code pantheon-files pantheon-mail pantheon-music pantheon-photos pantheon-screencast pantheon-shortcut-overlay pantheon-terminal pantheon-videos simple-scan pantheon-session pantheon switchboard-plugin-desktop" > /mnt/pantheon-packages.txt + DM="lightdm" +elif [[ "$DE" == "Enlightenment" ]]; then + arch-chroot /mnt pacman -S --quiet --noconfirm enlightenment terminology +elif [[ "$DE" == "Xfce" ]]; then + arch-chroot /mnt pacman -S --quiet --noconfirm xfce4 xfce4-goodies + DM="lightdm" +fi if [[ "$DM" == "" ]]; then inf "Your selected DE/WM doesn't have a standard display manager. Enter one of the below names, or leave blank for none"