feat: add vim leader key
parent
0834732302
commit
70ff410411
|
@ -53,7 +53,7 @@
|
|||
<p>Use both <code>\</code> and <code>;</code> as leader key:</p>
|
||||
<div class="highlight highlight-source-lua">
|
||||
<pre>vim.<span class="pl-smi">keymap</span>.<span class="pl-c1">set</span>(<span class="pl-s"><span class="pl-pds">"</span>n<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>;<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span><leader><span class="pl-pds">"</span></span>, { remap <span class="pl-k">=</span> <span class="pl-c1">true</span> })
|
||||
vim.<span class="pl-smi">keymap</span>.<span class="pl-c1">set</span>(<span class="pl-s"><span class="pl-pds">"</span>n<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>q<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>:q<CR><span class="pl-pds">"</span></span>)</pre>
|
||||
vim.<span class="pl-smi">keymap</span>.<span class="pl-c1">set</span>(<span class="pl-s"><span class="pl-pds">"</span>n<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>'<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span><leader><span class="pl-pds">"</span></span>, { remap <span class="pl-k">=</span> <span class="pl-c1">true</span> })</pre>
|
||||
</div>
|
||||
<p>Search multiple words:</p>
|
||||
<div class="highlight highlight-source-viml">
|
||||
|
|
|
@ -8,7 +8,7 @@ Use both `\` and `;` as leader key:
|
|||
|
||||
```lua
|
||||
vim.keymap.set("n", ";", "<leader>", { remap = true })
|
||||
vim.keymap.set("n", "q", ":q<CR>")
|
||||
vim.keymap.set("n", "'", "<leader>", { remap = true })
|
||||
```
|
||||
|
||||
Search multiple words:
|
||||
|
|
Loading…
Reference in New Issue