summaryrefslogtreecommitdiff
path: root/bin/first_stage.sh
diff options
context:
space:
mode:
authorxengineering <mail2xengineering@protonmail.com>2019-11-14 19:36:03 +0100
committerxengineering <mail2xengineering@protonmail.com>2019-11-14 19:36:03 +0100
commit6716e1b213d8108dac86d688f17016faa7f03c1a (patch)
treec47e8bb29235dfc39c01de802b467c2d3f053c07 /bin/first_stage.sh
parentb872b3eba4209f7a3c7c554a020eb6b4af606d80 (diff)
downloadarchinstall-6716e1b213d8108dac86d688f17016faa7f03c1a.tar
archinstall-6716e1b213d8108dac86d688f17016faa7f03c1a.tar.zst
archinstall-6716e1b213d8108dac86d688f17016faa7f03c1a.zip
Improved code readability and avoided output redirect to /dev/null.
Diffstat (limited to 'bin/first_stage.sh')
-rw-r--r--bin/first_stage.sh30
1 files changed, 9 insertions, 21 deletions
diff --git a/bin/first_stage.sh b/bin/first_stage.sh
index 0970049..a27641a 100644
--- a/bin/first_stage.sh
+++ b/bin/first_stage.sh
@@ -98,24 +98,11 @@ else
fi
-# Update the system clock
-
-timedatectl set-ntp true
-if [ $? -eq 0 ]; then
- echo "Updated system clock - OK"
- echo ""
- sleep $DELAY
-else
- echo "Could not update system clock - FAILED"
- exit
-fi
-
-
# Partitioning
-wipefs -a $disk_path > /dev/null # make sure that fdisk does not ask for
- # removing signatures which breaks the script
-fdisk $disk_path > /dev/null 2> /dev/null << EOF
+wipefs -a $disk_path # make sure that fdisk does not ask for removing
+ # signatures which breaks the script
+fdisk $disk_path << EOF
g
n
1
@@ -137,10 +124,10 @@ echo ""
# Create Filesystems
-mkfs.fat -F32 $boot_partition_path > /dev/null 2> /dev/null
-mkfs.ext4 $root_partition_path > /dev/null 2> /dev/null
-fatlabel $boot_partition_path "BOOT" > /dev/null
-e2label $root_partition_path "ROOT" > /dev/null
+mkfs.fat -F32 $boot_partition_path
+mkfs.ext4 $root_partition_path
+fatlabel $boot_partition_path "BOOT"
+e2label $root_partition_path "ROOT"
echo "Created filesystems - OK"
sleep $DELAY
echo ""
@@ -181,7 +168,8 @@ echo ""
# Launch second stage in chroot
-echo "bash $REPOSITORY_PATH/bin/second_stage.sh $hostname ${disk_path}1 $REPOSITORY_PATH" | arch-chroot /mnt
+echo "bash $REPOSITORY_PATH/bin/second_stage.sh $hostname \
+${disk_path}1 $REPOSITORY_PATH" | arch-chroot /mnt
# Copy log from live image to root partition