Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Remove some unused mappings that are just clobbering

  • Loading branch information...
commit 57402f5593b1710a361f6f0bd692d1b833dc9551 1 parent c02604a
@kalbasit kalbasit authored
View
4 README.md
@@ -215,10 +215,6 @@ Janus ships with a number of basic customizations for vim:
sudo password when writing
* `<F4>` toggles paste mode
* `<leader>fef` formats the entire file
-* `,.` (comma followed by a dot) opens the next buffer
-* `,m` (comma followed by m) opens the previous buffer
-* `;'` (semicolon followed by a single quote) switches to next tab
-* `;l` (semicolon followed by l) switches to previous tab
* `<leader>u` converts the entire word to uppercace
* `<leader>l` converts the entire word to lowercase
* `<leader>U` converts the first char of a word to uppercase
View
10 janus/vim/core/before/plugin/mappings.vim
@@ -13,16 +13,6 @@ imap <silent> <F4> <ESC>:set invpaste<CR>:set paste?<CR>
" format the entire file
nmap <leader>fef ggVG=
-" Next buffer
-nmap <silent> ,. :bnext<CR>
-
-" Previous buffer
-nmap <silent> ,m :bprev<CR>
-
-" Next tab
-nmap <silent> ;' :tabnext<CR>
-nmap <silent> ;l :tabprev<CR>
-
" upper/lower word
nmap <leader>u mQviwU`Q
nmap <leader>l mQviwu`Q
View
4 janus/vim/core/janus/doc/janus.txt
@@ -234,10 +234,6 @@ Janus ships with a number of basic customizations for vim:
sudo password when writing.
* `<F4>` Toggles paste mode
* `<leader>fef` format the entire file
-* `,.` (comma followed by a dot) opens the next buffer.
-* `,m` (comma followed by m) opens the previous buffer.
-* `;'` (semi-column followed by a single quote) switch to next tab.
-* `;l` (semi-column followed by l) switch to previous tab.
* `<leader>u` Convert the entire word to uppercace.
* `<leader>l` Convert the entire word to lowercase.
* `<leader>U` Convert the first char of a word to uppercase.

10 comments on commit 57402f5

@HusseinMorsy

I used these mappings every day.

@alexeymorozov

How do you switch buffer without this mappings?

@kalbasit
Owner

Oops sorry guys, the ;' and ;l were clobbering the ; key which repeats character findings like f and t and were slowing me down a lot..

Anyway you have 2 choices, either use :bn and :bp for switching buffers and :tabn and tabp for switching tabs, or you simply copy/paster the following into your .vimrc.after file:

nmap <silent> ,. :bnext<CR>
nmap <silent> ,m :bprev<CR>
nmap <silent> ;' :tabnext<CR>
nmap <silent> ;l :tabprev<CR>

which basically kinda reverts this commit..

@samgranieri

This just bit me in the ass today when I upgraded janus. It's probably a better thing to not clobber over vim defaults

@camsong

I used these mappings every day, not a good idea to remove it.

@joshthecoder

Yeah I use these tab switching shortcuts a lot as well. Guess I'll just add this back into my vimrc as suggested.

@kalbasit
Owner

@joshthecode @camsong @samgranieri @rekky @HusseinMorsy The Unimpaired plugin provides better shortcuts than what we used to have. [b to go to the previous buffer, ]b to go to the next buffer. It was included in Janus since the beginning I just missed them I guess.

I advise you to check :help unimpaired a lot of mappings are provided, they are easy to use and all of them useful!

Let me know if that helps!

/cc @tpope

@jeroendv

the unimpaired plugin doesn't provide an bracket idiom for tab switching though. Or does it?

@tpope

It doesn't. I've received pull requests to add such maps before, but I've had trouble parting with one of the few remaining free letter maps when gt is already so easy.

@jeroendv

Damn, I should really read the whole vim manual. I love vim, I use it everywhere I can and have been doing so for quite some time, and yet not a week goes by when I don't learn something new. And to make matters worse, usually the things I learn very often seem like basic things. So yes ... Thank You! for teaching me the gt command!

Please sign in to comment.
Something went wrong with that request. Please try again.