From deb521d7624acb918120d1bf3f66ca924bd3146c Mon Sep 17 00:00:00 2001 From: Stochastica Date: Sun, 3 Jan 2021 02:45:58 -0500 Subject: [PATCH] Change symlink scheme and add vim-amino as submodule --- .gitmodules | 3 +++ home/vim/vim-amino | 1 + symlinks.sh | 30 +++++++++++++++++++----------- 3 files changed, 23 insertions(+), 11 deletions(-) create mode 100644 .gitmodules create mode 160000 home/vim/vim-amino diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..d2be4f9 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "home/vim/vim-amino"] + path = home/vim/vim-amino + url = git@gitlab.com:Stochastica/vim-amino.git diff --git a/home/vim/vim-amino b/home/vim/vim-amino new file mode 160000 index 0000000..e662f56 --- /dev/null +++ b/home/vim/vim-amino @@ -0,0 +1 @@ +Subproject commit e662f56e98b20e0c9b9500380cf136d9044e76b4 diff --git a/symlinks.sh b/symlinks.sh index c9c0a36..6dc8dd1 100755 --- a/symlinks.sh +++ b/symlinks.sh @@ -1,25 +1,33 @@ #!/bin/bash # Calculate directory relative to $HOME -BASE=$(realpath --relative-to=$HOME $PWD) -echo $BASE - +DIR=$HOME +BASE=$(realpath --relative-to=$DIR $PWD) pushd $HOME >> /dev/null ln -vs $BASE/home/vimrc .vimrc ln -vs $BASE/home/bashrc .bashrc +popd >> /dev/null # Create ftplugin links -D_VIM_AFTER_FTPLUGIN=$HOME/.vim/after/ftplugin -mkdir -p $D_VIM_AFTER_FTPLUGIN -pushd $D_VIM_AFTER_FTPLUGIN >> /dev/null +DIR=$HOME/.vim/after/ftplugin +BASE=$(realpath --relative-to=$DIR $PWD) +mkdir -p $DIR +pushd $DIR >> /dev/null ln -vs $BASE/home/vim/after/ftplugin/tex.vim . popd >> /dev/null -D_CONFIG_FISH=$HOME/.config/fish -mkdir -p $D_CONFIG_FISH -pushd $D_CONFIG_FISH >> /dev/null +DIR=$HOME/.vim/colors +BASE=$(realpath --relative-to=$DIR $PWD) +mkdir -p $DIR +pushd $DIR >> /dev/null +ln -vs $BASE/home/vim/vim-amino/amino.vim . +popd >> /dev/null + + +DIR=$HOME/.config/fish +BASE=$(realpath --relative-to=$DIR $PWD) +mkdir -p $DIR +pushd $DIR >> /dev/null ln -vs $BASE/home/fish/fishd_color . ln -vs $BASE/home/fish/functions . popd >> /dev/null - -popd >> /dev/null