diff --git a/flavours/i3.flavour/install.sh b/flavours/i3.flavour/install.sh index 0c34f0f..e2b3f1c 100755 --- a/flavours/i3.flavour/install.sh +++ b/flavours/i3.flavour/install.sh @@ -3,7 +3,14 @@ echo "~> Installing i3" pacstrap /mnt i3 feh xcompmgr dmenu acpi +user=$(ls /mnt/home) +if [ "$user" == "" ]; then + path="/mnt/etc/skel/" +else + path="/mnt/home/$user/" +fi + echo "~> Creating .xinitrc" -echo "xcompmgr -c &" > /mnt/home/*/.xinitrc -echo "feh --bg-fill ~/background.jpg" >> /mnt/home/*/.xinitrc -echo "exec i3" >> /mnt/home/*/.xinitrc +echo "xcompmgr -c &" > $path/.xinitrc +echo "feh --bg-fill ~/background.jpg" >> $path/.xinitrc +echo "exec i3" >> $path/.xinitrc diff --git a/flavours/unsplash.flavour/install.sh b/flavours/unsplash.flavour/install.sh index 489c975..d6f69c2 100755 --- a/flavours/unsplash.flavour/install.sh +++ b/flavours/unsplash.flavour/install.sh @@ -2,4 +2,6 @@ echo "~> Grabbing a random image from unsplash.com..." -wget https://unsplash.com/photos/$(curl https://unsplash.com/search/photos/forest | grep -oE "photo=([a-zA-Z0-9_\\-]*)" | shuf -n 1 | sed -e "s/photo=//g")/download -o /mnt/home/*/background.jpg +mkdir -p /mnt/etc/wallpapers/ + +wget https://unsplash.com/photos/$(curl https://unsplash.com/search/photos/forest | grep -oE "photo=([a-zA-Z0-9_\\-]*)" | shuf -n 1 | sed -e "s/photo=//g")/download -o /mnt/etc/wallpapers/forest.jpg