2013-04-27 08:51:39 +00:00
|
|
|
FILES = bashrc vimrc zshrc emacs.el gitconfig screenrc commonshrc \
|
2013-11-01 14:14:58 +00:00
|
|
|
gnomerc gvimrc muttrc
|
2013-11-01 18:27:13 +00:00
|
|
|
FILES2 = msmtprc
|
2008-03-16 21:02:24 +00:00
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
.PHONY: install clean check
|
2011-07-28 20:05:16 +00:00
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
install: install-conf install-vim-pathogen
|
2011-07-28 20:05:16 +00:00
|
|
|
|
2013-12-29 17:32:58 +00:00
|
|
|
ifeq ($(OS),Windows_NT)
|
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
install-conf:
|
2013-12-29 17:32:58 +00:00
|
|
|
mkdir -p $(HOME)\vimfiles\autoload
|
|
|
|
cp gitconfig $(HOME)\.gitconfig
|
|
|
|
cp vimrc $(HOME)\_vimrc
|
|
|
|
cp gvimrc $(HOME)\_gvimrc
|
|
|
|
cp vim-pathogen/autoload/pathogen.vim $(HOME)\vimfiles\autoload
|
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
VIM_PATHOGEN_DIR = $(HOME)\vimfiles\bundle
|
|
|
|
|
2013-12-29 17:32:58 +00:00
|
|
|
else
|
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
install-conf: $(FILES)
|
2013-05-19 21:33:53 +00:00
|
|
|
mkdir -p ~/.ssh ~/.vim/autoload
|
2011-07-28 20:05:16 +00:00
|
|
|
for i in $(FILES); do install -m0644 $$i ~/.$$i; done
|
2013-11-01 18:27:13 +00:00
|
|
|
for i in $(FILES2); do install -m0600 $$i ~/.$$i; done
|
2013-05-19 21:33:53 +00:00
|
|
|
install -m0644 vim-pathogen/autoload/pathogen.vim ~/.vim/autoload/
|
2011-07-28 20:05:16 +00:00
|
|
|
|
2013-04-27 08:51:39 +00:00
|
|
|
check: $(FILES)
|
|
|
|
for i in $(FILES); do diff -u ~/.$$i $$i; done
|
2011-07-28 20:05:16 +00:00
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
VIM_PATHOGEN_DIR = $(HOME)/.vim/bundle
|
|
|
|
|
2013-12-29 17:32:58 +00:00
|
|
|
endif
|
|
|
|
|
2013-12-29 17:46:59 +00:00
|
|
|
vim_inst_bundle = cd $(subst \,/,$(VIM_PATHOGEN_DIR)) && if cd $(1); then git pull; else git clone $(2); fi
|
|
|
|
|
|
|
|
install-vim-pathogen:
|
|
|
|
mkdir -p $(VIM_PATHOGEN_DIR)
|
|
|
|
$(call vim_inst_bundle, vim-sensible, https://github.com/tpope/vim-sensible.git)
|
|
|
|
$(call vim_inst_bundle, jellybeans.vim, https://github.com/nanotech/jellybeans.vim.git)
|
|
|
|
$(call vim_inst_bundle, vim-coffee-script, https://github.com/kchmck/vim-coffee-script.git)
|
2014-02-05 18:51:11 +00:00
|
|
|
$(call vim_inst_bundle, vim-airline, https://github.com/bling/vim-airline.git)
|
|
|
|
$(call vim_inst_bundle, tagbar, https://github.com/majutsushi/tagbar.git)
|
|
|
|
$(call vim_inst_bundle, YouCompleteMe, https://github.com/Valloric/YouCompleteMe.git)
|
2013-12-29 17:46:59 +00:00
|
|
|
|
2013-12-29 17:32:58 +00:00
|
|
|
clean:
|
|
|
|
|
2011-07-28 20:05:16 +00:00
|
|
|
%: %.m4
|
|
|
|
m4 $< >$@
|