commit 9b4001379f071d28b58e0de63ac33170d400e18e
parent 0e47b8e7f48f7cfa437db69ae171c6e8ecce5f69
Author: Alex Balgavy <EMAIL>
Date: Sat, 7 Sep 2019 15:57:53 -0400
install.sh: fixes
Former-commit-id: 4a40ddf3e7ebe2ea0e6cc08ff5d9bb6ca3f6e0ee
Diffstat:
2 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/install.sh b/install.sh
@@ -8,6 +8,8 @@ if [ $(pwd) != "$HOME/.dotfiles" ]; then
exit 1
fi
+cd "$(dirname $0)"
+
if ! [ -f "./install.sh" ]; then
echo "Please cd into $HOME/.dotfiles before running the script."
exit 1
@@ -37,6 +39,7 @@ read -n 1 -p "Install all dotfiles? [Y/n]" yn
echo
case $yn in
[Yy]* )
+ sed -i -e "s:MY_HOME_DIR:$HOME:" vim/vimrc git/gitconfig
scripts/conf use $(find . -maxdepth 1 -type d ! -iwholename "*.git*")
echo "Dotfiles installed."
echo "Run \`conf\` for more help."
diff --git a/scripts/conf b/scripts/conf
@@ -95,6 +95,7 @@ use_files() {
done
;;
"vim")
+ mkdir -p "~/.vim"
lncommand "$DOTFILES/vim/vimrc" "$HOME/.vimrc" # vimrc points directly to other vim configs
lncommand "$DOTFILES/vim/idea.vimrc" "$HOME/.ideavimrc" # ideavimrc has to be separate
find "$DOTFILES/vim/" -mindepth 1 -maxdepth 1 -type d -exec ln -sv {} "$HOME"/.vim/ \;