luaPackages.tree-sitter-orgmode: init at 1.3.2-1

This commit is contained in:
Austin Horstman
2024-11-16 17:31:59 -06:00
parent 66aa98b290
commit aad44b3412
3 changed files with 44 additions and 3 deletions

View File

@@ -148,6 +148,7 @@ tiktoken_core,,,,,,natsukium
tl,,,,,,mephistophiles
toml-edit,,,,,5.1,mrcjkb
tree-sitter-norg,,,,,5.1,mrcjkb
tree-sitter-orgmode,,,,,,
vstruct,,,,,,
vusted,,,,,,figsoda
xml2lua,,,,,,teto
1 name rockspec ref server version luaversion maintainers
148 tl mephistophiles
149 toml-edit 5.1 mrcjkb
150 tree-sitter-norg 5.1 mrcjkb
151 tree-sitter-orgmode
152 vstruct
153 vusted figsoda
154 xml2lua teto

View File

@@ -3523,6 +3523,28 @@ buildLuarocksPackage {
};
}) {};
tree-sitter-orgmode = callPackage({ buildLuarocksPackage, fetchurl, fetchzip, luarocks-build-treesitter-parser }:
buildLuarocksPackage {
pname = "tree-sitter-orgmode";
version = "1.3.2-1";
knownRockspec = (fetchurl {
url = "mirror://luarocks/tree-sitter-orgmode-1.3.2-1.rockspec";
sha256 = "1md45ic96yf3agay30w9icr9c1v5fs0p6zs4dd5d0clrsc9029c4";
}).outPath;
src = fetchzip {
url = "https://github.com/nvim-orgmode/tree-sitter-org/archive/v1.3.2.zip";
sha256 = "1y1dyabvmm2q51nmi58lv0zf7sdz066i319s5j3ch6abcm1wv24i";
};
nativeBuildInputs = [ luarocks-build-treesitter-parser ];
meta = {
homepage = "https://github.com/nvim-orgmode/tree-sitter-org";
description = "A fork of tree-sitter-org, for use with the orgmode Neovim plugin";
license.fullName = "MIT";
};
}) {};
vstruct = callPackage({ buildLuarocksPackage, fetchFromGitHub, fetchurl, luaOlder }:
buildLuarocksPackage {
pname = "vstruct";

View File

@@ -838,6 +838,12 @@ in
nativeBuildInputs = oa.nativeBuildInputs ++ [ cargo rustPlatform.cargoSetupHook ];
});
tl = prev.tl.overrideAttrs ({
preConfigure = ''
rm luarocks.lock
'';
});
toml-edit = prev.toml-edit.overrideAttrs (oa: {
cargoDeps = rustPlatform.fetchCargoTarball {
@@ -866,9 +872,21 @@ in
];
});
tl = prev.tl.overrideAttrs ({
preConfigure = ''
rm luarocks.lock
tree-sitter-orgmode = prev.tree-sitter-orgmode.overrideAttrs (oa: {
propagatedBuildInputs =
let
# HACK: luarocks-nix puts rockspec build dependencies in the nativeBuildInputs,
# but that doesn't seem to work
lua = lib.head oa.propagatedBuildInputs;
in
oa.propagatedBuildInputs
++ [
lua.pkgs.luarocks-build-treesitter-parser
tree-sitter
];
preInstall = ''
export HOME="$TMPDIR";
'';
});