lazyvim/lua
Thomas Vandal b30c0312ea
fix(autocmds): replace vim.hl.on_yank with vim.hl.hl_op for nvim-0.13 and above (#7171)
## Description

<!-- Describe the big picture of your changes to communicate to the
maintainers
  why we should accept this pull request. -->

A recent PR (https://github.com/neovim/neovim/pull/39777) replaced
`vim.hl.on_yank` with a more generic `vim.hl.hl_op` and deprecated the
former.

This PR simply checks for `nvim-0.13` support and uses the new interface
if available.

This removes a deprecation warning and will avoid an error when
`on_yank` gets deprecated in the nvim 0.14 release.

Thanks!

## Checklist

- [x] I've read the
[CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md)
guidelines.
2026-05-26 15:27:06 +02:00
..
lazyvim fix(autocmds): replace vim.hl.on_yank with vim.hl.hl_op for nvim-0.13 and above (#7171) 2026-05-26 15:27:06 +02:00