Neovim extension for C++ Insights
Like cppinsights.vim. However, it contains a lua module of cppinsights, without dependency of cppinsights.
Dependence
- llvm
- clang
# ArchLinux
sudo pacman -S clang llvm llvm-libs
# Nix
# use nix-shell to create a virtual environment then build
Install
rocks.nvim
Command style
:Rocks install cppinsights.nvim
Declare style
~/.config/nvim/rocks.toml:
[plugins] "cppinsights.nvim" = "scm"
Then
:Rocks sync
or:
$ luarocks --lua-version 5.1 --local --tree ~/.local/share/nvim/rocks install cppinsights.nvim # ~/.local/share/nvim/rocks is the default rocks tree path # you can change it according to your vim.g.rocks_nvim.rocks_path
Configure
Refer config.lua:
require('cppinsights.nvim').setup({ -- ... })
Usage
:Insights[!] ...
!will display diff result....is arguments.