-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Cheatsheet for Keymaps #19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
paras-verma
wants to merge
1
commit into
LunarVim:master
Choose a base branch
from
paras-verma:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
# KeyMap Cheat-Sheet | ||
|
||
For anyone who is just starting with this neovim config! | ||
|
||
##### Note: | ||
|
||
- Vim Commands still work as they do one vanilla neovim | ||
- All keybinds can be changed according to one's preference in the `keymaps.lua` file located at `.../nvim/lua/user/lsp/` | ||
|
||
- To make edits enter (Debian): | ||
|
||
```sh | ||
cd ~/.config/nvim/lua/lsp | ||
nvim keymaps.lua | ||
``` | ||
|
||
- [Explainer (Video)](https://www.youtube.com/watch?v=435-amtVYJ8&list=PLhoH5vyxr6Qq41NFL4GvhFp-WLd5xzIzZ&index=3) | ||
|
||
- All commands are case sensitive | ||
- Both `<CTRL>` keys (R, L) are supported for commands requiring to press one | ||
- Press `<SPACE>` to open | ||
|
||
**Helper Menu can be accessed via `<SPACE>`** | ||
|
||
## Normal mode | ||
|
||
One can trigger these key-binds directly | ||
|
||
#### Buffers (Open Files) Navigation | ||
|
||
| Key-Combination | Action | Vim Key-Combination | | ||
| :-------------: | :------------------: | :-----------------: | | ||
| `<SHIFT>+l` | Open Next buffer | `:bnext` | | ||
| `<SHIFT>+h` | Open Previous buffer | `:bprevious` | | ||
| `<SPACE>+c` | Close Current Buffer | `:bd` | | ||
|
||
#### Window Navigation | ||
|
||
| Key-Combination | Action | | ||
| :-------------: | :------------------: | | ||
| `<CTRL>+h` | Move to Left Window | | ||
| `<CTRL>+j` | Move to Window Below | | ||
| `<CTRL>+k` | Move to Window Above | | ||
| `<CTRL>+l` | Move to Right Window | | ||
|
||
#### Window Resize (with arrows) | ||
|
||
| Key-Combination | Action | Vim Key-Combination | | ||
| :-------------: | :-------------: | :-------------------: | | ||
| `<CTRL>+Up` | Increase Height | `:resize -2` | | ||
| `<CTRL>+Down` | Decrease Height | `:resize +2` | | ||
| `<CTRL>+Left` | Increase Width | `:vertical resize -2` | | ||
| `<CTRL>+Right` | Decrease Width | `:vertical resize +2` | | ||
|
||
> Note: Up, Down, Left and Right are the Arrow keys | ||
|
||
#### Move text | ||
|
||
| Key-Combination | Action | Vim Key-Combination | | ||
| :-------------: | :----------: | :-----------------: | | ||
| `<ALT>+j` | Move line up | `:m .+1` | | ||
| `<ALT>+k` | Move line up | `:m .-2` | | ||
|
||
#### Text Editing | ||
|
||
| Key-Combination | Action | Vim Key-Combination | | ||
| :-------------: | :--------------: | :-----------------: | | ||
| `i` | Insert Mode | `i` | | ||
| `jk` | Exit Insert Mode | `<ESC>` | | ||
|
||
## Visual Mode | ||
|
||
One needs to be in the visual mode for these binds to work | ||
|
||
> Note: Press `v` to enter visual mode | ||
|
||
#### Add Indentation | ||
|
||
| Key-Combination | Action | Vim Key-Combination | | ||
| :-------------: | :-----------: | :-----------------: | | ||
| `<` | Remove Indent | `<gv` | | ||
| `>` | Add Indent | `>gv` | | ||
|
||
#### Move text | ||
|
||
| Key-Combination | Action | Vim Key-Combination | | ||
| :-------------: | :-------: | :-----------------: | | ||
| `<ALT>+j` | Move Down | `:m .+1` | | ||
| `<ALT>+k` | Move Up | `:m .-2` | | ||
|
||
**For those who are beginning with vim/neovim please visit this [site](https://devhints.io/vim) for the basic commands** | ||
|
||
Feel free to contribute more to this file! |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one -> in? on?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ion?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Talking about the grammar I think, in the line
they do one vanilla neovim
, should bethey do in/on neovim
.