From 579a870230b148d893698c5e2b19a71ba32ed472 Mon Sep 17 00:00:00 2001 From: Fernando Schauenburg Date: Thu, 22 Jul 2021 16:24:17 +0200 Subject: [PATCH] bootstrap: make it runnable from anywhere I was previously using relative paths to $PWD with the implicit assumption that I would always run `bootstrap` from the dotfiles root directory. This commit fixes that. --- bootstrap | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bootstrap b/bootstrap index 93b5548..dd63970 100755 --- a/bootstrap +++ b/bootstrap @@ -147,7 +147,7 @@ task_ensure_directories() { task_link_dotfiles() { heading "Link dotfiles" echo "$DOTFILES" | while read -r dest src; do - file_link "$src" "$dest" + file_link "$src" "$DOTFILES_DIR/$dest" done } @@ -180,14 +180,14 @@ task_prune_broken_bin() { task_link_local_bin() { heading "Link local commands" - for cmd in bin/*; do + for cmd in "$DOTFILES_DIR/bin/"*; do file_link "$HOME/.local/bin/$(basename "$cmd")" "$cmd" done } task_link_dircolors() { heading "Link dircolors" - for f in dircolors/*; do + for f in "$DOTFILES_DIR/dircolors/"*; do file_link "$XDG_CONFIG_HOME/dircolors/$(basename "$f")" "$f" done }