Delete setup.sh

This commit is contained in:
proledatarian 2022-02-16 11:47:59 +00:00
parent bc8550201c
commit cd6c4c01af
1 changed files with 0 additions and 94 deletions

View File

@ -1,94 +0,0 @@
#!/bin/bash
# Updating mirrors using reflector.
echo "Updating mirrors.."
echo -e
#reflector --verbose --latest 10 --country Germany --age 24 --protocol https --sort rate --save /etc/pacman.d/mirrorlist
reflector --verbose --latest 10 --age 24 --protocol https --sort rate --save /etc/pacman.d/mirrorlist &&
echo -e
echo "Done."
# Installing base system.
echo "Installing basic packages.."
echo -e
pacstrap /mnt base base-devel firefox konsole linux linux-firmware linux-zen lvm2 networkmanager nano plasma-desktop sddm sddm-kcm &&
echo -e
echo "Base system installed."
echo -e
# Generating fstab.
echo "Generating fstab."
genfstab -Up /mnt > /mnt/etc/fstab &&
echo "Installed fstab."
# Setting hostname.
echo "Please enter a hostname:"
read host &&
echo $host > /mnt/etc/hostname
echo "Hostname set."
# Setting locale.
echo "Setting and generating locale."
echo -e
localegen=$(cat /mnt/etc/locale.gen)
cat <<EOF >/mnt/etc/locale.gen
en_US.UTF-8 UTF-8
de_DE.UTF-8 UTF-8
EOF
echo "${localegen}" >>/mnt/etc/locale.gen
arch-chroot /mnt locale-gen
echo "LANG=de_DE.UTF-8" >/mnt/etc/locale.conf
echo -e
echo "Done."
# Editing mkinitcpio.conf.
echo "Editing /etc/mkinitcpio.conf."
echo -e
sed -i '7s/.*/MODULES=(ext4)/' /mnt/etc/mkinitcpio.conf &&
sed -i '52s/.*/HOOKS=(base udev autodetect modconf block keyboard keymap encrypt lvm2 filesystems fsck shutdown)/' /mnt/etc/mkinitcpio.conf &&
echo -e
echo "Done."
# Creating inital ramdisk.
echo "Creating inital ramdisk for linux-zen."
echo -e
arch-chroot /mnt mkinitcpio -p linux-zen &&
echo "Done."
# Enable network and display manager.
echo "Enabling Networkmanager and display manager (sddm)."
echo -e
arch-chroot /mnt systemctl enable NetworkManager sddm &&
echo -e
echo "Done."
echo "Setting root password:"
arch-chroot /mnt passwd
arch-chroot /mnt bootctl install
cp ./arch.conf /mnt/boot/loader/entries
cp ./arch-fallback.conf /mnt/boot/loader/entries
echo "timeout 1" >> /mnt/boot/loader/loader.conf
echo "default arch.conf" >> /mnt/boot/loader/loader.conf
localectl --no-convert set-keymap de-latin1-nodeadkeys
echo "Username?"
read user
useradd -m $user &&
passwd $user &&
gpasswd -a $user wheel
sed -i '82s/.*/%wheel ALL=(ALL) ALL/' /mnt/etc/sudoers
mkdir /mnt/etc/sddm.conf.d
echo "[Autologin]" >> /mnt/etc/sddm.conf.d/autologin.conf
echo "User=hans" >> /mnt/etc/sddm.conf.d/autologin.conf
echo "Session=plasma" >> /mnt/etc/sddm.conf.d/autologin.conf
umount /mnt/boot
umount /mnt/home
reboot