Skip to content

Commit 6768e88

Browse files
committed
Update to automate the check for UEFI. Cleanup bloat.sh and added vm detection.
1 parent 9348bdb commit 6768e88

2 files changed

Lines changed: 8 additions & 16 deletions

File tree

bloat.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ read -p "My Customs: " custom
7474
if [[ $custom == "y" || $custom == "Y" || $custom == "yes" || $custom == "Yes" ]]
7575
then
7676
pacstrap /mnt alacritty
77-
arch-chroot /mnt /bin/bash -c "paru --skipreview --removemake --cleanafter timeshift"
78-
arch-chroot /mnt /bin/bash -c "flatpak install flathub -y --noninteractive --app org.gnome.Boxes org.gnome.Calculator org.gnome.Calendar org.gnome.Characters org.gnome.clocks org.gnome.eog org.gnome.Epiphany org.gnome.Extensions org.gnome.Evince org.gnome.FileRoller org.gnome.font-viewer org.gnome.Geary org.gnome.gedit org.gnome.Photos org.gnome.Totem org.gnome.Weather"
77+
arch-chroot /mnt /bin/bash -c "paru -S timeshift --removemake --cleanafter"
78+
arch-chroot /mnt /bin/bash -c "flatpak install flathub -y --noninteractive --app org.gnome.Boxes org.gnome.Calculator org.gnome.Calendar org.gnome.Characters org.gnome.clocks org.gnome.eog org.gnome.Epiphany org.gnome.Extensions org.gnome.Evince org.gnome.FileRoller org.gnome.font-viewer org.gnome.Geary org.gnome.gedit org.gnome.Photos org.gnome.Totem org.gnome.Weather org.libreoffice.LibreOffice"
7979
fi
8080
exit 0

simplyarch.sh

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,9 @@ then
9090
echo
9191
while ! [[ "$partType" =~ ^(1|2)$ ]]
9292
do
93-
echo "Please select partition type: e.g: 1 for EXT4 and 2 for BTRFS"
93+
echo "Please select partition type (1/2):"
94+
echo "1. EXT4"
95+
echo "2. BTRFS"
9496
read -p "Partition Type: " partType
9597
done
9698
clear
@@ -115,17 +117,7 @@ then
115117
;;
116118
esac
117119
clear
118-
echo "Partition Table"
119-
echo
120-
lsblk
121-
echo
122-
while ! [[ "$bootType" =~ ^(1|2)$ ]]
123-
do
124-
echo "Please select boot type: e.g: 1 for UEFI and 2 for BIOS"
125-
read -p "Partition Type: " bootType
126-
done
127-
clear
128-
if [ $bootType == 1 ]
120+
if [[ -d /sys/firmware/efi ]]
129121
then
130122
echo "Partition Table"
131123
echo
@@ -172,7 +164,7 @@ then
172164
echo "This process may take a while, please wait..."
173165
sleep 1
174166
# Install base system
175-
if [ $bootType == 1 ]
167+
if [[ -d /sys/firmware/efi ]]
176168
then
177169
pacstrap /mnt base base-devel linux linux-firmware linux-headers grub efibootmgr os-prober bash-completion sudo nano vim networkmanager ntfs-3g neofetch htop git reflector xdg-user-dirs e2fsprogs man-db
178170
else
@@ -202,7 +194,7 @@ then
202194
echo "::1 localhost" >> /mnt/etc/hosts
203195
echo "127.0.1.1 $hostname.localdomain $hostname" >> /mnt/etc/hosts
204196
# grub
205-
if [ $bootType == 1 ]
197+
if [[ -d /sys/firmware/efi ]]
206198
then
207199
arch-chroot /mnt /bin/bash -c "grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=Arch"
208200
else

0 commit comments

Comments
 (0)