mirror of
https://github.com/bertptrs/vimconfig.git
synced 2025-12-25 20:40:32 +01:00
Rewrite configuration to be stowed.
This commit is contained in:
22
.gitmodules
vendored
22
.gitmodules
vendored
@@ -1,33 +1,33 @@
|
|||||||
[submodule "vim/pathogen"]
|
[submodule "vim/pathogen"]
|
||||||
path = vim/pathogen
|
path = vim/.vim/pathogen
|
||||||
url = https://github.com/tpope/vim-pathogen
|
url = https://github.com/tpope/vim-pathogen
|
||||||
[submodule "vim/bundle/molokai"]
|
[submodule "vim/bundle/molokai"]
|
||||||
path = vim/bundle/molokai
|
path = vim/.vim/bundle/molokai
|
||||||
url = https://github.com/tomasr/molokai
|
url = https://github.com/tomasr/molokai
|
||||||
[submodule "vim/bundle/vim-markdown"]
|
[submodule "vim/bundle/vim-markdown"]
|
||||||
path = vim/bundle/vim-markdown
|
path = vim/.vim/bundle/vim-markdown
|
||||||
url = https://github.com/tpope/vim-markdown
|
url = https://github.com/tpope/vim-markdown
|
||||||
[submodule "vim/bundle/vim-less"]
|
[submodule "vim/bundle/vim-less"]
|
||||||
path = vim/bundle/vim-less
|
path = vim/.vim/bundle/vim-less
|
||||||
url = https://github.com/lunaru/vim-less
|
url = https://github.com/lunaru/vim-less
|
||||||
[submodule "vim/bundle/syntastic"]
|
[submodule "vim/bundle/syntastic"]
|
||||||
path = vim/bundle/syntastic
|
path = vim/.vim/bundle/syntastic
|
||||||
url = https://github.com/scrooloose/syntastic.git
|
url = https://github.com/scrooloose/syntastic.git
|
||||||
[submodule "vim/bundle/vim-javascript"]
|
[submodule "vim/bundle/vim-javascript"]
|
||||||
path = vim/bundle/vim-javascript
|
path = vim/.vim/bundle/vim-javascript
|
||||||
url = https://github.com/pangloss/vim-javascript
|
url = https://github.com/pangloss/vim-javascript
|
||||||
[submodule "vim/bundle/vim-vimlint"]
|
[submodule "vim/bundle/vim-vimlint"]
|
||||||
path = vim/bundle/vim-vimlint
|
path = vim/.vim/bundle/vim-vimlint
|
||||||
url = https://github.com/syngan/vim-vimlint
|
url = https://github.com/syngan/vim-vimlint
|
||||||
[submodule "vim/bundle/vim-vimlparser"]
|
[submodule "vim/bundle/vim-vimlparser"]
|
||||||
path = vim/bundle/vim-vimlparser
|
path = vim/.vim/bundle/vim-vimlparser
|
||||||
url = https://github.com/ynkdir/vim-vimlparser
|
url = https://github.com/ynkdir/vim-vimlparser
|
||||||
[submodule "vim/bundle/vim-latex"]
|
[submodule "vim/bundle/vim-latex"]
|
||||||
path = vim/bundle/vim-latex
|
path = vim/.vim/bundle/vim-latex
|
||||||
url = git@github.com:lervag/vim-latex.git
|
url = git@github.com:lervag/vim-latex.git
|
||||||
[submodule "vim/bundle/shebang"]
|
[submodule "vim/bundle/shebang"]
|
||||||
path = vim/bundle/shebang
|
path = vim/.vim/bundle/shebang
|
||||||
url = https://github.com/vim-scripts/Shebang
|
url = https://github.com/vim-scripts/Shebang
|
||||||
[submodule "vim/bundle/indentLine"]
|
[submodule "vim/bundle/indentLine"]
|
||||||
path = vim/bundle/indentLine
|
path = vim/.vim/bundle/indentLine
|
||||||
url = https://github.com/Yggdroot/indentLine
|
url = https://github.com/Yggdroot/indentLine
|
||||||
|
|||||||
27
install.sh
27
install.sh
@@ -2,6 +2,10 @@
|
|||||||
|
|
||||||
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
|
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
|
||||||
|
|
||||||
|
commandAvailable() {
|
||||||
|
command -v $1 >/dev/null
|
||||||
|
}
|
||||||
|
|
||||||
confirm () {
|
confirm () {
|
||||||
# call with a prompt string or use a default
|
# call with a prompt string or use a default
|
||||||
read -r -p "${1:-Are you sure? [y/N]} " response
|
read -r -p "${1:-Are you sure? [y/N]} " response
|
||||||
@@ -34,21 +38,24 @@ git submodule init &> /dev/null && git submodule update &> /dev/null \
|
|||||||
|
|
||||||
echo "done."
|
echo "done."
|
||||||
|
|
||||||
|
if ! commandAvailable stow; then
|
||||||
|
echo "Error: stow not available. Skipping installation." >&2;
|
||||||
|
exit 1;
|
||||||
|
fi
|
||||||
|
|
||||||
# Install vim
|
# Install vim
|
||||||
|
|
||||||
echo "Installing vim."
|
if commandAvailable vim
|
||||||
|
then
|
||||||
confirmAndLink $DIR/vim/vimrc $HOME/.vimrc
|
echo "Installing configuration files for vim.";
|
||||||
confirmAndLink $DIR/vim $HOME/.vim
|
stow -t $HOME vim
|
||||||
|
fi
|
||||||
|
|
||||||
# Install zsh, if relevant.
|
# Install zsh, if relevant.
|
||||||
if which zsh
|
if commandAvailable zsh
|
||||||
then
|
then
|
||||||
echo "Installing zsh"
|
echo "Installing configuration files for zsh."
|
||||||
|
stow -t $HOME zsh
|
||||||
confirmAndLink $DIR/zshrc $HOME/.zshrc
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Installation finished."
|
echo "Installation finished."
|
||||||
|
|||||||
Reference in New Issue
Block a user