Skip to content

Commit

Permalink
Merge pull request chxuan#21 from dofy/master
Browse files Browse the repository at this point in the history
support custom config
  • Loading branch information
chxuan authored Dec 8, 2017
2 parents 15838df + 4e2bb96 commit 6f96f95
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .vimrc
Original file line number Diff line number Diff line change
Expand Up @@ -389,3 +389,8 @@ nmap <Leader><Leader>il :IndentLinesToggle<CR>
" pydiction
let g:pydiction_location='~/.vim/bundle/pydiction/complete-dict'
let g:pydiction_menu_height=10

" 个性化
if filereadable(expand($HOME . '/.vimrc.local'))
source $HOME/.vimrc.local
endif
12 changes: 12 additions & 0 deletions .vimrc.local
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
"## etc.

"## settings

"### 开启相对行号
"set relativenumber

"### open firefox for markdown-preview in macOS
"let g:mkdp_path_to_chrome = 'open -a /Applications/Firefox.app'

"## plugins
"Plugin 'kchmck/vim-coffee-script' " support CoffeeScript
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ An automatic configuration program for vim
sudo ./install.sh
```

个性化
------------

修改 `~/.vimrc.local` 文件内容,以启用个性化定制,可覆盖 `~/.vimrc` 中的设置。

插件列表
------------
- [Vundle][4] - 基于Git仓库的插件管理软件。
Expand Down
15 changes: 11 additions & 4 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,17 +88,24 @@ function install_prepare_software_on_ubuntu()
function copy_files()
{
rm -rf ~/.vimrc
cp .vimrc ~
# cp .vimrc ~
ln -s ${PWD}/.vimrc ~

rm -rf ~/.vimrc.local
cp ${PWD}/.vimrc.local ~

rm -rf ~/.ycm_extra_conf.py
cp .ycm_extra_conf.py ~
# cp .ycm_extra_conf.py ~
ln -s ${PWD}/.ycm_extra_conf.py ~

mkdir ~/.vim
rm -rf ~/.vim/plugin
cp -R ./plugin ~/.vim
# cp -R ./plugin ~/.vim
ln -s ${PWD}/./plugin ~/.vim

rm -rf ~/.vim/colors
cp -R ./colors ~/.vim
# cp -R ./colors ~/.vim
ln -s ${PWD}/./colors ~/.vim
}

# 安装mac平台字体
Expand Down
1 change: 1 addition & 0 deletions uninstall.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash

sudo rm -rf ~/.vimrc.local
sudo rm -rf ~/.vimrc
sudo rm -rf ~/.vim

Expand Down

0 comments on commit 6f96f95

Please sign in to comment.