Skip to content

Commit

Permalink
use a different extension 'dsymlink' so bootstrap can link any file i…
Browse files Browse the repository at this point in the history
…nside a .directory
  • Loading branch information
schangj09 committed Apr 8, 2024
1 parent e0e3186 commit db41cc8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
File renamed without changes.
10 changes: 7 additions & 3 deletions script/bootstrap
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,13 @@ install_dotfiles () {
link_file "$src" "$dst"
done

src=$DOTFILES_ROOT/gnupg/gpg.conf.symlink
dst=$HOME/.gnupg/gpg.conf
link_file "$src" "$dst"
# find files with '.dsymlink' and link to a file inside a .directory
# e.g. './gnupg/gpg.conf.dsymlink' links to '~/.gnupg/gpg.conf'
for src in $(find -H "$DOTFILES_ROOT" -maxdepth 2 -name '*.dsymlink' -not -path '*.git*')
do
dst="$HOME/.$(basename $(dirname $src))/$(basename "${src%.*}")"
link_file "$src" "$dst"
done

}

Expand Down

0 comments on commit db41cc8

Please sign in to comment.