Neovim install - nutthawit/alpine-dotfile GitHub Wiki

Installation

Install external dependencies

cargo install ripgrep --locked
cargo install fd-find --locked
doas apk add font-noto-emoji

Install neovim

doas apk add neovim neovim-doc

Install kickstart

Fork this repo

git clone [email protected]:nutthawit/kickstart.nvim.git ~/.config/nvim

Install LuaRock

wget https://luarocks.org/releases/luarocks-3.12.2.tar.gz
tar zxpf luarocks-3.12.2.tar.gz
cd cd luarocks-3.12.2 

doas apk add lua5.1-dev

./configure
make
doas make install

To enable rust-analyzer, search for rust_analyzer = {} in the file ~/.config/nvim/init.lua, uncomment it, and update it with the following content:

local servers = {
  -- clangd = {},
  -- gopls = {},
  -- pyright = {},
  rust_analyzer = {
    settings = {
      ['rust-analyzer'] = {
        diagnostics = {
          enable = false,
        },
        imports = {
          granularity = {
            group = 'module',
          },
          prefix = 'self',
        },
        cargo = {
          buildScripts = {
            enable = true,
          },
        },
        procMacro = {
          enable = true,
        },
      },
    },
  },
--
-- ...

[!NOTE] See docs for extra settings.