To edit opened file, you need to switch to INSERT mode. This can be done by pressing Insert key.
|
|||
In the insert mode, these shorctuts can be used to move the cursor:
|
|||
|
Go to the beginning of the line |
||
|
Go to the end of the line |
||
|
Move one character to the left |
||
|
Move one character to the right |
||
|
Go to the next line |
||
|
Go to the previous line |
Advertisement
To select text via keyboard, you need to enter VISUAL mode. To do this, first exit the insert mode by pressing Esc.
|
|||
Once you place the cursor at the beginning of the part we want to select, we use the keys CTRL + v to enter the V-BLOC (Visual Block) mode.
|
|||
Now moving with the cursor we will see that our selection will be highlighted.
|
|||
|
Copy selection to the clipboard |
||
|
Delete selection |
||
Text search |
|||
|
then type "/search key" : Search |
||
|
Move to next match |
||
|
Move to previous match |
||
When you finished searching, the highlight can be removed by the command Shift + :noh (no highlight).
|
|||
Saving the document |
|||
First press Esc to exit INSERT mode then press Shift + :w to save file with the current name.
|
|||
To save with different name, use the following command:
|
|||
:w /path/to/new/file_or_position
|
|||
To save and quit, use Shift + :wq (write and quit).
|
|||
Source: rockylinux.org
|
What is your favorite NvChad hotkey? Do you have any useful tips for it? Let other users know below.
1088428 169
488689 8
406504 371
350269 6
297036 5
269909 32
21 hours ago
21 hours ago
Yesterday
2 days ago
2 days ago
2 days ago
Latest articles