3Basic.html (2505B)
1 <!DOCTYPE html> 2 <html lang="en-GB"> 3 <head> 4 <meta charset="UTF-8"> 5 <meta name="author" content="Shipwreckt"> 6 <meta name="viewport" content="width=device-width, initial-scale=1.0"> 7 <title>Basic commands</title> 8 <link rel="stylesheet" href="../../styles.css"> 9 <link rel="icon" href="../../Images/favi.png" type="image/x-icon"> 10 </head> 11 <body> 12 <header> 13 <nav> 14 <ul> 15 <li><a href="../../index.html">Home</a></li> 16 <li><a href="../../links.html">Links</a></li> 17 <li><a href="../../projects.html">Projects</a></li> 18 <li><a href="../../contact.html">Contact</a></li> 19 </ul> 20 </nav> 21 </header> 22 <main> 23 24 <h1>Basic Commands</h1><hr> 25 26 <p>There are over 100 commands in Neovim, and thankfully, you don't need to know all of them to use the text editor—just a few basic commands are enough.</p><hr> 27 28 <h3>Copy and Paste in Neovim</h3> 29 <p>Instead of using <kbd>Ctrl</kbd> + <kbd>C</kbd> and <kbd>Ctrl</kbd> + <kbd>V</kbd>, Neovim uses <kbd>y</kbd> and <kbd>p</kbd> for copying and pasting lines:</p> 30 <ul> 31 <li><kbd>yy</kbd> - Copies an entire line in normal mode</li> 32 <li><kbd>y3</kbd> - Copies 3 lines in normal mode</li> 33 <li><kbd>y</kbd> - Copies selected text in visual mode</li> 34 </ul> 35 <hr> 36 37 <h3>Deleting Lines</h3> 38 <ul> 39 <li><kbd>dd</kbd> - Deletes a single line in normal mode</li> 40 <li><kbd>d3</kbd> - Deletes 3 lines in normal mode</li> 41 <li><kbd>d</kbd> - Deletes selected text in visual mode</li> 42 </ul> 43 <hr> 44 45 <h3>Undo and Redo</h3> 46 <ul> 47 <li><kbd>u</kbd> - Undo the last change</li> 48 <li><kbd>Ctrl</kbd> + <kbd>r</kbd> - Redo the undone change</li> 49 </ul> 50 <hr> 51 52 <h3>Saving and Quitting</h3> 53 <ul> 54 <li><kbd>:w</kbd> - Save the current file</li> 55 <li><kbd>:wq</kbd> or <kbd>ZZ</kbd> - Save and quit</li> 56 <li><kbd>:q</kbd> - Quit (only if no unsaved changes)</li> 57 <li><kbd>:q!</kbd> or <kbd>ZQ</kbd> - Quit without saving changes</li> 58 </ul> 59 <hr> 60 61 <h3>Searching</h3> 62 <ul> 63 <li><kbd>/Linux</kbd> - Search for 'Linux' (case-sensitive)</li> 64 <li><kbd>n</kbd> - Go to the next found 'Linux'</li> 65 <li><kbd>N</kbd> - Go to the previous 'Linux'</li> 66 </ul> 67 <hr> 68 69 <pre style="text-align: center;"><a href="../neovimlist.html">Back</a></pre> 70 </main> 71 </body> 72 </html>