mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-04-13 16:18:36 +00:00
init/autocmds: add example to the autocmds option
Some checks failed
Check for typos in the source tree / check-typos (push) Has been cancelled
Some checks failed
Check for typos in the source tree / check-typos (push) Has been cancelled
This commit is contained in:
parent
15fbd146aa
commit
7b58caaa9f
1 changed files with 14 additions and 0 deletions
|
@ -126,6 +126,20 @@ in {
|
|||
autocmds = mkOption {
|
||||
type = listOf autocommandType;
|
||||
default = [];
|
||||
example = literalExpression ''
|
||||
[
|
||||
{
|
||||
enable = true;
|
||||
desc = "Highlight yanks on copy";
|
||||
pattern = ["*"];
|
||||
callback = lib.generators.mkLuaInline '''
|
||||
function()
|
||||
vim.highlight.on_yank({ timeout = 500 })
|
||||
end
|
||||
''';
|
||||
}
|
||||
]
|
||||
'';
|
||||
description = ''
|
||||
A list of Neovim autocommands to be registered.
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue