FIX provide path for home

This commit is contained in:
Nathan Dwarshuis 2021-06-12 00:55:48 -04:00
parent 1a68c373cd
commit 4b4975df8a
1 changed files with 13 additions and 5 deletions

View File

@ -12,6 +12,13 @@
# permissions in sudoers.
pkgsrc_dir="$1"
if [[ -z "${2+set}" ]]; then
install_root="$HOME"
else
install_root="$2"
fi
makepkg_tmp=/tmp/bootstrap-makepkg
mk_makepkg_dir() {
@ -34,8 +41,8 @@ call_makepkg() {
}
run_install_scripts() {
~/.config/rofi-extras/install_deps
~/.config/xmonad/install_deps
"$install_root/.config/rofi-extras/install_deps"
"$install_root/.config/xmonad/install_deps"
}
run_yay() {
@ -57,8 +64,7 @@ run_yay() {
## AUR pkgs needed for spotify
spotify_pkgs=(gconf)
MAKEFLAGS="-j$(nproc)" \
yay --needed --noconfirm --norebuild --removemake -S \
yay --needed --noconfirm --norebuild --removemake -S \
"${dunst_pkgs[@]}" \
"${emacs_pkgs[@]}" \
"${gtk_pkgs[@]}" \
@ -92,12 +98,14 @@ clean_up() {
trap 'clean_up' ERR
if [ "$#" -ne 1 ]; then
echo "Usage: bootstrap_pkgs [CUSTOM_PKGBUILD_SRC]"
echo "Usage: bootstrap_pkgs CUSTOM_PKGBUILD_SRC [INSTALL_ROOT]"
exit 1
fi
try_update
run_install_scripts
run_yay
mk_makepkg_dir