packages/nvim-treesitter-nightly: init
this took way too long because i didn't realise .withPlugins only overrides the original one aaaaaaa
This commit is contained in:
parent
ed5c719ff7
commit
e2ee6940ab
5 changed files with 46 additions and 1 deletions
17
flake.lock
generated
17
flake.lock
generated
|
|
@ -357,6 +357,22 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nvim-treesitter": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1637761627,
|
||||
"narHash": "sha256-E8/CY1JjalIlyzI2Is2ZrhD1DXCfuX4u81qj+7CXYTg=",
|
||||
"owner": "nvim-treesitter",
|
||||
"repo": "nvim-treesitter",
|
||||
"rev": "8016b74cea415596be405b14067d2938914b2e18",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nvim-treesitter",
|
||||
"repo": "nvim-treesitter",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"oglfPatches": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
|
@ -508,6 +524,7 @@
|
|||
"nix-gaming": "nix-gaming",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"no-double-back-pc": "no-double-back-pc",
|
||||
"nvim-treesitter": "nvim-treesitter",
|
||||
"packwiz": "packwiz",
|
||||
"powercord-overlay": "powercord-overlay",
|
||||
"powercord-popout-fix": "powercord-popout-fix",
|
||||
|
|
|
|||
|
|
@ -23,6 +23,7 @@
|
|||
discord-tokyonight = { url = "github:DanisDGK/zelk-customizations"; flake = false; };
|
||||
discover = { url = "github:trigg/Discover"; flake = false; };
|
||||
linux-tkg = { url = "github:Frogging-Family/linux-tkg"; flake = false; };
|
||||
nvim-treesitter = { url = "github:nvim-treesitter/nvim-treesitter"; flake = false; };
|
||||
packwiz = { url = "github:comp500/packwiz"; flake = false; };
|
||||
spotify-adblock = { url = "github:abba23/spotify-adblock"; flake = false; };
|
||||
tree-sitter-glimmer = { url = "github:alexlafroscia/tree-sitter-glimmer"; flake = false; };
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ in {
|
|||
cmp_luasnip
|
||||
luasnip
|
||||
|
||||
(nvim-treesitter.withPlugins (p: with p; [
|
||||
(pkgs.me.nvim-treesitter-nightly.withPlugins (p: with p; [
|
||||
tree-sitter-comment
|
||||
tree-sitter-c-sharp
|
||||
pkgs.me.tree-sitter-glimmer
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
discord-tokyonight = callPackage ./discord-tokyonight { inherit inputs; };
|
||||
discover-overlay = callPackage ./discover { inherit inputs; };
|
||||
linux-lava = callPackage ./linux-lava { inherit inputs; };
|
||||
nvim-treesitter-nightly = callPackage ./nvim-treesitter-nightly { inherit inputs; };
|
||||
packwiz = callPackage ./packwiz { inherit inputs; };
|
||||
spotify-adblock = callPackage ./spotify-adblock { inherit inputs; };
|
||||
tree-sitter-glimmer = callPackage ./tree-sitter-glimmer { inherit inputs; };
|
||||
|
|
|
|||
26
packages/nvim-treesitter-nightly/default.nix
Normal file
26
packages/nvim-treesitter-nightly/default.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{
|
||||
inputs,
|
||||
tree-sitter,
|
||||
vimPlugins
|
||||
}:
|
||||
let
|
||||
nvim-treesitter-nightly = vimPlugins.nvim-treesitter.overrideAttrs(_: {
|
||||
pname = "nvim-treesitter-nightly";
|
||||
version = inputs.nvim-treesitter.lastModifiedDate;
|
||||
src = inputs.nvim-treesitter;
|
||||
});
|
||||
in nvim-treesitter-nightly.overrideAttrs(o: {
|
||||
passthru = o.passthru // {
|
||||
unwrapped = nvim-treesitter-nightly;
|
||||
withPlugins = grammarFn: nvim-treesitter-nightly.overrideAttrs (_: {
|
||||
postPatch =
|
||||
let
|
||||
grammars = tree-sitter.withPlugins grammarFn;
|
||||
in
|
||||
''
|
||||
rm -r parser
|
||||
ln -s ${grammars} parser
|
||||
'';
|
||||
});
|
||||
};
|
||||
})
|
||||
Loading…
Add table
Add a link
Reference in a new issue