index.html :: rss :: github :: telegram :: email

linux: autocomplete for kernel sources in nvim

06 Sep 2024
  1. build kernel with Clang (you may have to answer clang-related questions, e.g. KMSAN, stask init, etc...):

    cd ~/src/linux
    make CC=clang
    
  2. generate compile_commands.json:

    python3 ./scripts/clang-tools/gen_compile_commands.py
    
  3. start nvim in a kernel source dir and wait for indexing completion.

  4. good luck, have fun!