python312Packages.tree-sitter-sql: init at 0.3.8
This commit is contained in:
committed by
Doron Behar
parent
814663e400
commit
baec4b1cbf
@@ -0,0 +1,59 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
|
||||
# build-system
|
||||
setuptools,
|
||||
tree-sitter-sql,
|
||||
|
||||
#optional-dependencies
|
||||
tree-sitter,
|
||||
}:
|
||||
buildPythonPackage rec {
|
||||
pname = "tree-sitter-sql";
|
||||
version = "0.3.8";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "DerekStride";
|
||||
repo = "tree-sitter-sql";
|
||||
tag = "v${version}";
|
||||
hash = "sha256-8gdbbz187sV8I+PJHubFyyQwGUqvo05Yw1DX7rOK4DI=";
|
||||
};
|
||||
|
||||
postUnpack = ''
|
||||
cp -rf ${tree-sitter-sql.passthru.parsers}/* $sourceRoot
|
||||
'';
|
||||
|
||||
build-system = [
|
||||
setuptools
|
||||
];
|
||||
|
||||
passthru = {
|
||||
# As mentioned in https://github.com/DerekStride/tree-sitter-sql README
|
||||
# generated tree sitter parser files necessary for compilation
|
||||
# are separately distributed on the gh-pages branch
|
||||
parsers = fetchFromGitHub {
|
||||
owner = "DerekStride";
|
||||
repo = "tree-sitter-sql";
|
||||
rev = "9853b887c5e4309de273922b681cc7bc09e30c78/gh-pages";
|
||||
hash = "sha256-p60nphbSN+O5fOlL06nw0qgQFpmvoNCTmLzDvUC/JGs=";
|
||||
};
|
||||
};
|
||||
|
||||
optional-dependencies = {
|
||||
core = [
|
||||
tree-sitter
|
||||
];
|
||||
};
|
||||
|
||||
pythonImportsCheck = [ "tree_sitter_sql" ];
|
||||
|
||||
meta = {
|
||||
description = "sql grammar for tree-sitter";
|
||||
homepage = "https://github.com/DerekStride/tree-sitter-sql";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ pcboy ];
|
||||
};
|
||||
}
|
||||
@@ -17780,6 +17780,8 @@ self: super: with self; {
|
||||
|
||||
tree-sitter-rust = callPackage ../development/python-modules/tree-sitter-rust { };
|
||||
|
||||
tree-sitter-sql = callPackage ../development/python-modules/tree-sitter-sql { };
|
||||
|
||||
tree-sitter-yaml = callPackage ../development/python-modules/tree-sitter-yaml { };
|
||||
|
||||
treelib = callPackage ../development/python-modules/treelib { };
|
||||
|
||||
Reference in New Issue
Block a user