mirror of
https://github.com/rwinkhart/artix-install-script.git
synced 2026-08-30 05:36:40 -04:00
Fixed failure to share variables between scripts
This commit is contained in:
+12
-11
@@ -1,17 +1,18 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Importing Variables
|
||||
formfactor=$1[1]
|
||||
threadsminusone=$1[2]
|
||||
gpu=$1[3]
|
||||
intel_vaapi_driver=$1[4]
|
||||
boot=$1[5]
|
||||
disk=$1[6]
|
||||
username=$1[7]
|
||||
userpassword=$1[8]
|
||||
rootpassword=$1[9]
|
||||
timezone=$1[10]
|
||||
swap=$1[11]
|
||||
args=("$@")
|
||||
formfactor=${args[0]}
|
||||
threadsminusone=${args[1]}
|
||||
gpu=${args[2]}
|
||||
boot=${args[3]}
|
||||
disk=${args[4]}
|
||||
username=${args[5]}
|
||||
userpassword=${args[6]}
|
||||
rootpassword=${args[7]}
|
||||
timezone=${args[8]}
|
||||
swap=${args[9]}
|
||||
intel_vaapi_driver=${args[10]}
|
||||
|
||||
# configuring locale and clock Settings
|
||||
echo 'en_US.UTF-8 UTF-8' > /etc/locale.gen
|
||||
|
||||
+2
-2
@@ -175,9 +175,9 @@ for int in "${interfaces[@]}"; do
|
||||
done
|
||||
|
||||
# create array of variables to pass to part 2
|
||||
var_export=($formfactor $threadsminusone $gpu $intel_vaapi_driver $boot $disk0 $username $userpassword $rootpassword $timezone $swap)
|
||||
var_export=($formfactor $threadsminusone $gpu $boot $disk0 $username $userpassword $rootpassword $timezone $swap $intel_vaapi_driver)
|
||||
|
||||
# download and initiate part 2
|
||||
curl https://raw.githubusercontent.com/rwinkhart/artix-install-script/main/chrootInstall.sh -o /mnt/chrootInstall.sh
|
||||
chmod +x /mnt/chrootInstall.sh
|
||||
artix-chroot /mnt /chrootInstall.sh $var_export
|
||||
artix-chroot /mnt /chrootInstall.sh "${var_export[@]}"
|
||||
|
||||
Reference in New Issue
Block a user