summaryrefslogtreecommitdiff
path: root/home-manager/modules/apps/nvim/default.nix
blob: 366cdf000235bfb32e5032055d4e5e65724e267d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
{ pkgs, config, ...}:
let 
  treesitterWithGrammars = (pkgs.vimPlugins.nvim-treesitter.withPlugins (p : [
    p.bash 
    p.comment
    p.css 
    p.dockerfile
    p.gitattributes 
    p.gitignore
    p.go
    p.gomod
    p.gowork
    p.rust 
    p.javascript 
    p.typescript
    p.json5
    p.json
    p.lua
    p.markdown
    p.nix
    p.python 
    p.java 
    p.rust
    p.toml 
    p.vue 
    p.yaml
    p.php
    p.latex 
  ]));
  treesitter-parsers = pkgs.symlinkJoin {
    name = "treesitter-parsers";
    paths = treesitterWithGrammars.dependencies;
  };

in 
{
  programs.neovim = {
    enable = true; 
     defaultEditor = true;
     viAlias = true; 
     vimAlias = true; 
  #   vimdiffAlias = true;
  #   # withPython3 = false; 
  #   # withNodeJs = false; 
  #   # withRuby = false; 
  #
     coc.enable = false; 
  # 
     plugins = [
      treesitterWithGrammars
     ];
  };

  home.file."./.config/nvim/lua/wilkuu/init.lua".text = ''
    require("wilkuu.set")
    require("wilkuu.remap")
  '';
  #vim.opt.runtimepath:append("${treesitter-parsers}")

  home.file."./.config/nvim/lua/wilkuu/nix.lua".text = ''
    return {
      vue_ts_plugin = "/home/wilkuu/.npm/@vue/typescript-plugin",
    } 
  '';


  # home.file."./.local/share/nvim/nix/nvim-treesitter/" = {
  #   source = treesitterWithGrammars; 
  #   recursive = true; 
  # };

  home.sessionPath = [
    "/home/wilkuu/.npm/bin/"
  ]; 

  home.packages = with pkgs; [
    lua
    lua-language-server
    gopls 
    go
    typescript
    nodejs_22 
    rustup
    nixd 
    nixfmt-rfc-style 
    pyright
    nodePackages.intelephense
    texlive.combined.scheme-full
    texlab
  ];

}