neovim/nix/package.nix

44 lines
856 B
Nix

{ pkgs, lib, ... }:
let
deps = with pkgs; [
lua
# Language Servers
rust-analyzer
nil
pyright
bash-language-server
lua-language-server
zls
typescript
nodePackages_latest.typescript-language-server
kdePackages.qtdeclarative # QML formatter
# Formatter
python311Packages.black # Python formatter
clang-tools
nodePackages_latest.prettier # JSON, JS, TS formatter
yamlfmt # YAML formatter
taplo # TOML formatter
rustfmt # Rust formatter
shfmt # Shell, Bash etc.
nixfmt-rfc-style
stylua # lua formatter
# Misc
ripgrep
rustc
cargo
nodejs_22
clang
tree-sitter
fd
luajitPackages.luarocks
wl-clipboard
];
in
pkgs.writeShellScriptBin "nvim" ''
export PATH=${lib.makeBinPath deps}:$PATH
${pkgs.neovim}/bin/nvim -u ${../init.lua}
''