From 2a8d1eca39ef8b9f6b6509c2ce3557e460f3ad6d Mon Sep 17 00:00:00 2001 From: Nimesh Ghelani Date: Fri, 21 Aug 2015 21:19:56 +0530 Subject: [PATCH 1/2] Add essential buffer commands --- index.md | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/index.md b/index.md index 510075c..aba51cf 100644 --- a/index.md +++ b/index.md @@ -98,7 +98,7 @@ Type any of these while some text is selected to apply the action * `:%s/old/new/g` - replace all old with new throughout file ([gn](https://github.com/vinitkumar/white-paper) is better though) * `:%s/old/new/gc` - replace all old with new throughout file with confirmations -##Working with multiple files +##Working with multiple files - Tabs * `:e filename` - Edit a file * `:tabe` - make a new tab * `gt` - go to the next tab @@ -110,6 +110,18 @@ Type any of these while some text is selected to apply the action * `ctrl+ww` - switch between windows * `ctrl+wq` - Quit a window +##Working with multiple files - Buffers +* `:enew` - edit a new, unnamed buffer +* `:ls` - list all open buffers +* `:bn` - go to the next buffer +* `:bp` - go to the previous buffer +* `:b[N]` - goto buffer numbered N + * ex. `:b2` will bring buffer numbered 2 to your tab +* `:b filename-prefix` - goto buffer with the corresponding filename-prefix +* `Ctrl+^` - Toggle between current and last buffer +* `Ctrl+o` - Go to the previous buffer you were in +* `Ctrl+i` - Reverse the effect of `Ctrl+o` + ##Marks Marks allow you to jump to designated points in your code. From 5e50d80e4aec090f5b3f08eb3a33f1eea0b37339 Mon Sep 17 00:00:00 2001 From: Nick Reilingh Date: Fri, 25 Dec 2020 14:33:25 -0500 Subject: [PATCH 2/2] fixes markdown header formatting --- index.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/index.md b/index.md index 858a7c1..6fe6e88 100644 --- a/index.md +++ b/index.md @@ -98,7 +98,7 @@ Type any of these while some text is selected to apply the action * `:%s/old/new/g` - replace all old with new throughout file ([gn](http://vimcasts.org/episodes/operating-on-search-matches-using-gn/) is better though) * `:%s/old/new/gc` - replace all old with new throughout file with confirmations -##Working with multiple files - Tabs +## Working with multiple files - Tabs * `:e filename` - Edit a file * `:tabe` - Make a new tab * `gt` - Go to the next tab @@ -110,7 +110,7 @@ Type any of these while some text is selected to apply the action * `ctrl+ww` - switch between windows * `ctrl+wq` - Quit a window -##Working with multiple files - Buffers +## Working with multiple files - Buffers * `:enew` - edit a new, unnamed buffer * `:ls` - list all open buffers * `:bn` - go to the next buffer @@ -122,10 +122,10 @@ Type any of these while some text is selected to apply the action * `Ctrl+o` - Go to the previous buffer you were in * `Ctrl+i` - Reverse the effect of `Ctrl+o` -##Marks +## Marks Marks allow you to jump to designated points in your code. -* `m{a-z}` - Set mark {a-z} at cursor position +* `m{a-z}` - Set mark {a-z} at cursor position * A capital mark {A-Z} sets a global mark and will work between files * `‘{a-z}` - move the cursor to the start of the line where the mark was set * `‘’` - go back to the previous jump location @@ -172,7 +172,7 @@ Vim is quite unpleasant out of the box. For example, typing `:w` for every file * `{ "keys": ["alt+r"], "command": "show_overlay", "args": {"overlay": "goto", "text": "@"} },` * [Add the ability to toggle Vintageous on and off](https://github.com/guillermooo/Vintageous/wiki/Toggling-Vintageous) * Mac users: you will not have the ability to hold down a navigation key (like holding j to go down). To fix this, run the commands specified here: [https://gist.github.com/kconragan/2510186](https://gist.github.com/kconragan/2510186) - + * Now you should be able to restart sublime and have a great Vim environment! Sweet Dude. ## Switch Caps Lock and Escape