mirror of
https://github.com/classy-giraffe/easy-arch.git
synced 2025-11-17 11:30:55 +00:00
Cosmetics.
This commit is contained in:
parent
d35b2d3b38
commit
af28d414d3
1 changed files with 4 additions and 10 deletions
14
easy-arch.sh
14
easy-arch.sh
|
|
@ -296,7 +296,7 @@ mkfs.fat -F 32 "$ESP" &>/dev/null
|
||||||
# Creating a LUKS Container for the root partition.
|
# Creating a LUKS Container for the root partition.
|
||||||
print "Creating LUKS Container for the root partition."
|
print "Creating LUKS Container for the root partition."
|
||||||
echo -n "$password" | cryptsetup luksFormat "$CRYPTROOT" -d -
|
echo -n "$password" | cryptsetup luksFormat "$CRYPTROOT" -d -
|
||||||
echo -n "$password" | cryptsetup open "$CRYPTROOT" cryptroot -d -
|
echo -n "$password" | cryptsetup open "$CRYPTROOT" cryptroot -d - &>/dev/null
|
||||||
BTRFS="/dev/mapper/cryptroot"
|
BTRFS="/dev/mapper/cryptroot"
|
||||||
|
|
||||||
# Formatting the LUKS Container as BTRFS.
|
# Formatting the LUKS Container as BTRFS.
|
||||||
|
|
@ -371,40 +371,34 @@ UUID=$(blkid -s UUID -o value $CRYPTROOT)
|
||||||
sed -i "\,^GRUB_CMDLINE_LINUX=\"\",s,\",&rd.luks.name=$UUID=cryptroot root=$BTRFS," /mnt/etc/default/grub
|
sed -i "\,^GRUB_CMDLINE_LINUX=\"\",s,\",&rd.luks.name=$UUID=cryptroot root=$BTRFS," /mnt/etc/default/grub
|
||||||
|
|
||||||
# Configuring the system.
|
# Configuring the system.
|
||||||
|
print "Configuring the system (timezone, system clock, initramfs, Snapper, GRUB)."
|
||||||
arch-chroot /mnt /bin/bash -e <<EOF
|
arch-chroot /mnt /bin/bash -e <<EOF
|
||||||
|
|
||||||
# Setting up timezone.
|
# Setting up timezone.
|
||||||
echo "Setting up the timezone."
|
|
||||||
ln -sf /usr/share/zoneinfo/$(curl -s http://ip-api.com/line?fields=timezone) /etc/localtime &>/dev/null
|
ln -sf /usr/share/zoneinfo/$(curl -s http://ip-api.com/line?fields=timezone) /etc/localtime &>/dev/null
|
||||||
|
|
||||||
# Setting up clock.
|
# Setting up clock.
|
||||||
echo "Setting up the system clock."
|
|
||||||
hwclock --systohc
|
hwclock --systohc
|
||||||
|
|
||||||
# Generating locales.
|
# Generating locales.
|
||||||
echo "Generating locales."
|
|
||||||
locale-gen &>/dev/null
|
locale-gen &>/dev/null
|
||||||
|
|
||||||
# Generating a new initramfs.
|
# Generating a new initramfs.
|
||||||
echo "Creating a new initramfs."
|
|
||||||
mkinitcpio -P &>/dev/null
|
mkinitcpio -P &>/dev/null
|
||||||
|
|
||||||
# Snapper configuration
|
# Snapper configuration.
|
||||||
echo "Configuring Snapper."
|
|
||||||
umount /.snapshots
|
umount /.snapshots
|
||||||
rm -r /.snapshots
|
rm -r /.snapshots
|
||||||
snapper --no-dbus -c root create-config /
|
snapper --no-dbus -c root create-config /
|
||||||
btrfs subvolume delete /.snapshots &>/dev/null
|
btrfs subvolume delete /.snapshots &>/dev/null
|
||||||
mkdir /.snapshots
|
mkdir /.snapshots
|
||||||
mount -a
|
mount -a &>/dev/null
|
||||||
chmod 750 /.snapshots
|
chmod 750 /.snapshots
|
||||||
|
|
||||||
# Installing GRUB.
|
# Installing GRUB.
|
||||||
echo "Installing GRUB on /boot."
|
|
||||||
grub-install --target=x86_64-efi --efi-directory=/boot/ --bootloader-id=GRUB &>/dev/null
|
grub-install --target=x86_64-efi --efi-directory=/boot/ --bootloader-id=GRUB &>/dev/null
|
||||||
|
|
||||||
# Creating grub config file.
|
# Creating grub config file.
|
||||||
echo "Creating GRUB config file."
|
|
||||||
grub-mkconfig -o /boot/grub/grub.cfg &>/dev/null
|
grub-mkconfig -o /boot/grub/grub.cfg &>/dev/null
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue