Created
May 14, 2011 05:15
-
-
Save kana/971940 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- s.vim.before 2011-05-14 14:12:34.000000000 +0900 | |
+++ s.vim.after 2011-05-14 14:12:27.000000000 +0900 | |
@@ -21,7 +21,6 @@ | |
" Basic {{{ | |
-"set no compatible | |
set nocompatible | |
"reset | |
@@ -40,8 +39,8 @@ | |
filetype on | |
" ruby - developer {{{ | |
-au FileType c set ts=8 sw=4 noexpandtab | |
-au FileType ruby set nowrap tabstop=8 tw=0 sw=2 expandtab | |
+au FileType c setlocal ts=8 sw=4 noexpandtab | |
+au FileType ruby setlocal nowrap tabstop=8 tw=0 sw=2 expandtab | |
let g:changelog_timeformat="%a %b %e %T %Y" | |
let g:changelog_username = "Shota Fukumori <[email protected]>" | |
" }}} | |
@@ -97,7 +96,6 @@ | |
set wrapscan | |
set incsearch | |
set hlsearch | |
-hi Search term=reverse ctermbg=LightBlue ctermfg=NONE | |
"}}} | |
"indent settings {{{ | |
@@ -140,7 +138,6 @@ | |
" Other {{{ | |
set noruler | |
-set nolist | |
set showmatch | |
set wrap | |
set title | |
@@ -162,16 +159,16 @@ | |
"}}} | |
"turn on the syntax-highlight {{{ | |
-syntax on | |
+syntax enable | |
" }}} | |
" search {{{ | |
-nmap n nzz | |
-nmap N Nzz | |
-nmap * *zz | |
-nmap # #zz | |
-nmap g* g*zz | |
-nmap g# g#zz | |
+noremap n nzz | |
+noremap N Nzz | |
+noremap * *zz | |
+noremap # #zz | |
+noremap g* g*zz | |
+noremap g# g#zz | |
" }}} | |
"pumheight {{{ | |
@@ -194,7 +191,7 @@ | |
"}}} | |
"help settings {{{ | |
-set helplang=ja | |
+set helplang=es | |
"}}} | |
lang en_US.UTF-8 | |
@@ -243,9 +240,9 @@ | |
"Rails etc autocmd {{{ | |
augroup Rails_etc | |
autocmd! | |
- autocmd BufNewFile,BufRead app/*/*.rhtml set ft=mason fenc=utf-8 | |
- autocmd BufNewFile,BufRead app/**/*.rb set ft=ruby fenc=utf-8 | |
- autocmd BufNewFile,BufRead app/**/*.yml set ft=ruby fenc=utf-8 | |
+ autocmd BufNewFile,BufRead app/*/*.rhtml setlocal ft=mason fenc=utf-8 | |
+ autocmd BufNewFile,BufRead app/**/*.rb setlocal ft=ruby fenc=utf-8 | |
+ autocmd BufNewFile,BufRead app/**/*.yml setlocal ft=ruby fenc=utf-8 | |
augroup END | |
"}}} | |
@@ -326,8 +323,7 @@ | |
nnoremap <silent> <C-a> :setl spell!<Return> | |
"move to line head | |
-nnoremap ~ <Home> | |
-vnoremap ~ <Home> | |
+noremap ~ <Home> | |
"key-mapping for edit vimrc | |
nnoremap <silent> <Space>ev :<C-u>tabedit $MYVIMRC<CR> | |
@@ -336,7 +332,7 @@ | |
nnoremap <silent> <Space>ea :source $MYVIMRC<Return> | |
"key-mapping for shift-n | |
-nnoremap m N | |
+noremap m N | |
"markdown.vim setting | |
if filereadable("/Users/sorah/local/bin/markdown.pl") | |
@@ -393,7 +389,6 @@ | |
"th :tabe ~/ | |
nnoremap th :tabe ~/ | |
nnoremap ts :tabe ~/sandbox/ | |
-nnoremap m :tabe ~/sandbox/ | |
nnoremap tr :tabe ~/sandbox/ruby/ | |
nnoremap tt :tabe ~/git/ruby/termtter/ | |
nnoremap tg :tabe ~/git | |
@@ -536,14 +531,14 @@ | |
call vimshell#set_execute_file('html,xhtml', 'firefox') | |
end | |
-let g:VimShell_enable_interactive = 1 | |
-let g:VimShell_enable_smart_case = 1 | |
+let g:vimshell_enable_interactive = 1 | |
+let g:vimshell_enable_smart_case = 1 | |
":cdd => :Cdd | |
cabbrev cdd Cdd | |
"Setf | |
-nnoremap <C-s> :<C-u>setf | |
+nnoremap <C-s> :<C-u>setf<Space> | |
"easy to save | |
nnoremap W :<C-u>w<Cr> | |
@@ -613,15 +608,15 @@ | |
"ew | |
-function! g:VimRcWriteEdit() | |
+function! s:VimRcWriteEdit() | |
write | |
edit | |
endfunction | |
-command! WriteEdit call g:VimRcWriteEdit() | |
+command! WriteEdit call s:VimRcWriteEdit() | |
cabbrev we WriteEdit | |
"open | |
-function! g:CallOpenCmd(...) | |
+function! s:CallOpenCmd(...) | |
if a:0 > 0 | |
if has('mac') | |
call system("open ".shellescape(a:1)) | |
@@ -636,10 +631,10 @@ | |
endif | |
endif | |
endfunction | |
-command! -nargs=? -complete=file Open call g:CallOpenCmd('<args>') | |
+command! -nargs=? -complete=file Open call s:CallOpenCmd('<args>') | |
"few | |
-function! g:Few(...) | |
+function! s:Few(...) | |
if a:0 > 0 | |
call system("few ".shellescape(expand(a:1))) | |
else | |
@@ -647,29 +642,29 @@ | |
call system("few ".shellescape(expand('%:p'))) | |
endif | |
endfunction | |
-command! -nargs=? -complete=file Few call g:Few('<args>') | |
+command! -nargs=? -complete=file Few call s:Few('<args>') | |
"notes | |
let g:notes_dir_path=expand("~")."/sandbox/document/memo" | |
-function! g:OpenNotes(fn) | |
+function! s:OpenNotes(fn) | |
execute ":tabe ".expand(g:notes_dir_path."/".a:fn.".mkd") | |
endfunction | |
function! OpenNoteHkn(a,b,c) | |
return substitute(system("ls -1 ". shellescape(g:notes_dir_path)), ".mkd", "", "g") | |
endfunction | |
-command! -nargs=1 -complete=custom,OpenNoteHkn Note call g:OpenNotes(<q-args>) | |
+command! -nargs=1 -complete=custom,OpenNoteHkn Note call s:OpenNotes(<q-args>) | |
nnoremap <C-e> :<C-u>Note | |
" RSpec | |
-function! g:QuickRunRSpecWithoutLine() | |
+function! s:QuickRunRSpecWithoutLine() | |
let g:quickrun_config['ruby.rspec'] = {'command': 'rspec'} | |
endfunction | |
-function! g:QuickRunRSpecWithLine() | |
+function! s:QuickRunRSpecWithLine() | |
let g:quickrun_config['ruby.rspec'] = {'command': "rspec -l {line('.')}"} | |
endfunction | |
-call g:QuickRunRSpecWithoutLine() | |
-command! QuickRSpecWithLine call g:QuickRunRSpecWithLine() | |
-command! QuickRSpec call g:QuickRunRSpecWithoutLine() | |
+call s:QuickRunRSpecWithoutLine() | |
+command! QuickRSpecWithLine call s:QuickRunRSpecWithLine() | |
+command! QuickRSpec call s:QuickRunRSpecWithoutLine() | |
augroup UjihisaRSpec | |
autocmd! | |
autocmd BufWinEnter,BufNewFile *_spec.rb set filetype=ruby.rspec |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- vim.before 2011-05-14 14:12:49.000000000 +0900 | |
+++ vim.after 2011-05-14 14:12:51.000000000 +0900 | |
@@ -1,15 +1,16 @@ | |
-set fileencodings=utf8 | |
+set fileencodings=ucs-bom,utf-8,euc-jp,cp932,iso-2022-jp | |
set encoding=utf-8 | |
-set termencoding=utf-8 | |
noremap <C-j> 3+ | |
noremap <C-k> 3- | |
nnoremap Y y$ | |
-noremap # :call ToggleCommentSelection()<CR> | |
+nnoremap # :call ToggleCommentSelection()<CR> | |
+vnoremap # :call ToggleCommentSelection()<CR> | |
nnoremap R gR | |
-nnoremap <Space>l :hide bn!<CR> | |
-nnoremap <Space>h :hide bp!<CR> | |
+nnoremap gR R | |
+nnoremap <Space>l :<C-u>hide bn<CR> | |
+nnoremap <Space>h :<C-u>hide bp<CR> | |
nnoremap <Tab> <C-w>w | |
-nnoremap <C-h> <C-w>W | |
+nnoremap <C-h> :<C-u>help<Space> | |
vnoremap s y:%s/<C-R>"//g<Left><Left> | |
set hidden | |
set autoread | |
@@ -69,7 +70,7 @@ | |
au BufNewFile,BufReadPost \cmakefile,*.mak setlocal list noexpandtab | |
au BufNewFile,WinEnter * hi ZenkakuSpace guibg=NONE gui=underline guifg=#90e09f| match ZenkakuSpace / / | |
- au FileType vim set sw=2 ts=2 sts=2 et | |
+ au FileType vim setlocal sw=2 ts=2 sts=2 et | |
au FileType c,cpp call C_Setting() | |
au FileType ruby call Ruby_Setting() | |
autocmd Syntax * call MySyntax() | |
@@ -87,15 +88,15 @@ | |
endfunction | |
function! C_Setting() | |
- set isk-=! | |
+ setlocal isk-=! | |
setlocal ts=4 sts=4 sw=4 noet | |
- set fo-=ro | |
+ setlocal fo-=ro | |
nnoremap <buffer> p p=`] | |
- set foldmethod=syntax | |
+ setlocal foldmethod=syntax | |
syn region myFold start="{" end="}" transparent fold | |
- set foldnestmax=1 | |
- iab case case<CR><C-D>break;<Up> | |
- iab default: default:<CR>break;<Up> | |
+ setlocal foldnestmax=1 | |
+ iab <buffer> case case<CR><C-D>break;<Up> | |
+ iab <buffer> default: default:<CR>break;<Up> | |
if filereadable("./Makefile") | |
setlocal makeprg=make | |
else | |
@@ -133,10 +134,8 @@ | |
endwhile | |
endfunction | |
-set term=builtin_linux | |
-set ttytype=builtin_linux | |
+syntax enable | |
colorscheme torte | |
-syntax on | |
view raw | |
gistfile1.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment