Skip to content

Commit

Permalink
Temporary fixes nix tree-sitter while waiting for unstable release
Browse files Browse the repository at this point in the history
issue: github.com/NixOS/nixpkgs/pull/173522
  • Loading branch information
pistachiology committed May 20, 2022
1 parent 5ecde45 commit 92d69d0
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 14 deletions.
18 changes: 9 additions & 9 deletions nixpkgs/flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 14 additions & 5 deletions nixpkgs/modules/neovim.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
{ config, pkgs, libs, lib, ... }:
let
tree-sitter = pkgs.tree-sitter.override {
extraGrammars = {
tree-sitter-nix = lib.importJSON ./tree-sitter-nix.json;
};
};
grammars = tree-sitter.allGrammars;
in
{
programs.neovim = {
enable = true;
Expand All @@ -24,7 +32,7 @@
'';

plugins = with pkgs.vimPlugins; [
(nvim-treesitter.withPlugins (p: pkgs.tree-sitter.allGrammars))
(nvim-treesitter.withPlugins (p: grammars))
markdown-preview-nvim
lightspeed-nvim
vim-prisma
Expand All @@ -33,10 +41,11 @@
};


xdg.configFile."nvim/fnl" = {
source = ../config/nvim/fnl;
recursive = true;
};
xdg.configFile."nvim/fnl" =
{
source = ../config/nvim/fnl;
recursive = true;
};

xdg.configFile."nvim/boot.lua" = {
source = ../config/nvim/init.lua;
Expand Down
11 changes: 11 additions & 0 deletions nixpkgs/modules/tree-sitter-nix.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"url": "https://github.com/cstrahan/tree-sitter-nix",
"rev": "6d6aaa50793b8265b6a8b6628577a0083d3b923d",
"date": "2021-11-29T00:27:21-06:00",
"path": "/nix/store/6cjadxvqbrh205lsqnk2rnzq3badxdxv-tree-sitter-nix",
"sha256": "0cbk6dqppasrvnm87pwfgm718z6b0xmy9m7zj8ysil0h8bklz1w9",
"fetchLFS": false,
"fetchSubmodules": false,
"deepClone": false,
"leaveDotGit": false
}

0 comments on commit 92d69d0

Please sign in to comment.