Added splitjoin plugin. Use sj and sk to split and join hashes into multiple lines.
This commit is contained in:
parent
33cdf98c49
commit
8e68cbeac0
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -166,3 +166,6 @@
|
||||
[submodule "vim/bundle/godlygeek-tabular"]
|
||||
path = vim/bundle/godlygeek-tabular
|
||||
url = https://github.com/godlygeek/tabular
|
||||
[submodule "vim/bundle/AndrewRadev-splitjoin"]
|
||||
path = vim/bundle/AndrewRadev-splitjoin
|
||||
url = https://github.com/AndrewRadev/splitjoin.vim
|
||||
|
@ -217,6 +217,10 @@ files contain key mappings as well (TODO: probably will move them out to skwp-ke
|
||||
* Cmd-/ - toggle comments (usually gcc from tComment)
|
||||
* gcp (comment a paragraph) added
|
||||
* ,t - Command-T fuzzy file selector (alternative to PeepOpen / LustyJuggler)
|
||||
* sj - split a line such as a hash {:foo => {:bar => :baz}} into a multiline hash (j = down)
|
||||
* sk - unsplit a link (k = up)
|
||||
* Ctrl-a - align things (type a character/expression to align by, works in visual mode or by itself)
|
||||
* sj and sk - split and unsplit things (like ruby hashes) into multiple lines
|
||||
|
||||
**Local Anonymous Bookmarking**
|
||||
|
||||
@ -262,7 +266,8 @@ Included vim plugins
|
||||
|
||||
**Utils**
|
||||
|
||||
* tabularize - align code effortlessly by using :Tabularize /[character] to align by a character, or try the mappings ,a= and ,a: to align by equals or colons
|
||||
* SplitJoin - easily split up things like ruby hashes into multiple lines or join them back together. Try :SplitjoinJoin and :SplitjoinSplit or use the bindings sj(split) and sk(unsplit) - mnemonically j and k are directions down and up
|
||||
* tabularize - align code effortlessly by using :Tabularize /[character] to align by a character, or try the keymaps
|
||||
* yankring - effortless sanity for pasting. every time you yank something it goes into a buffer. after hitting p to paste, use ctrl-p or ctrl-n to cycle through the paste options. great for when you accidentally overwrite your yank with a delete
|
||||
* surround - super easy quote and tag manipulation - ysiw" - sourround inner word with quotes. ci"' - change inner double quotes to single quotes, etc
|
||||
* greplace - use :Gsearch to find across many files, replace inside the changes, then :Greplace to do a replace across all matches
|
||||
|
1
vim/bundle/AndrewRadev-splitjoin
Submodule
1
vim/bundle/AndrewRadev-splitjoin
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 9896c3a62514ca0a2902acf37398ddc36fbcaa8f
|
@ -158,15 +158,16 @@ nnoremap <D-*> :let @/='\<<C-R>=expand("<cword>")<CR>\>'<CR>:set hls<CR>
|
||||
nnoremap ' `
|
||||
nnoremap ` '
|
||||
|
||||
" Tabularization. Hit ,a then type a character you want to align by
|
||||
" The mnemonic is 'a' for align
|
||||
" Tabularization. Hit Ctrl-a then type a character you want to align by
|
||||
if exists(":Tabularize")
|
||||
nmap ,a= :Tabularize /=<CR>
|
||||
vmap ,a= :Tabularize /=<CR>
|
||||
nmap ,a: :Tabularize /:\zs<CR>
|
||||
vmap ,a: :Tabularize /:\zs<CR>
|
||||
nmap <C-a> :Tabularize /
|
||||
vmap <C-a> :Tabularize /
|
||||
endif
|
||||
|
||||
" ===
|
||||
" SplitJoin plugin
|
||||
nmap sj :SplitjoinSplit<cr>
|
||||
nmap sk :SplitjoinJoin<cr>
|
||||
|
||||
" ============================
|
||||
" VimBookmarking
|
||||
|
Loading…
Reference in New Issue
Block a user