FILES = bashrc vimrc zshrc emacs.el gitconfig screenrc commonshrc \ gnomerc gvimrc muttrc FILES2 = msmtprc .PHONY: install clean check install: install-conf install-vim-vundle ifeq ($(OS),Windows_NT) install-conf: mkdir -p $(HOME)\vimfiles\autoload cp gitconfig $(HOME)\.gitconfig cp vimrc $(HOME)\_vimrc cp gvimrc $(HOME)\_gvimrc VIM_BUNDLE_DIR = $(HOME)/vimfiles/bundle else install-conf: $(FILES) mkdir -p ~/.ssh ~/.vim/autoload for i in $(FILES); do install -m0644 $$i ~/.$$i; done for i in $(FILES2); do install -m0600 $$i ~/.$$i; done check: $(FILES) for i in $(FILES); do diff -u ~/.$$i $$i; done VIM_BUNDLE_DIR = $(HOME)/.vim/bundle endif install-vim-vundle: mkdir -p $(VIM_BUNDLE_DIR) test -d $(VIM_BUNDLE_DIR)/vundle || git clone https://github.com/gmarik/vundle.git $(VIM_BUNDLE_DIR)/vundle clean: %: %.m4 m4 $< >$@