From 38169a981d295229474f1136fa8a8c3562fd157d Mon Sep 17 00:00:00 2001 From: Taus Date: Tue, 19 Mar 2024 15:07:02 +0000 Subject: [PATCH] Python: Shorten `tree-sitter-python` directory name The current name results in a path that is more than 260 characters long, and this causes issues for the build on Windows. --- python/extractor/tsg-python/Cargo.toml | 2 +- .../extractor/tsg-python/{tree-sitter-python => tsp}/.gitignore | 0 .../extractor/tsg-python/{tree-sitter-python => tsp}/.npmignore | 0 .../tsg-python/{tree-sitter-python => tsp}/BUILD.bazel | 0 .../extractor/tsg-python/{tree-sitter-python => tsp}/Cargo.toml | 0 python/extractor/tsg-python/{tree-sitter-python => tsp}/LICENSE | 0 .../extractor/tsg-python/{tree-sitter-python => tsp}/README.md | 0 .../tsg-python/{tree-sitter-python => tsp}/binding.gyp | 0 .../{tree-sitter-python => tsp}/bindings/node/binding.cc | 0 .../{tree-sitter-python => tsp}/bindings/node/index.js | 0 .../{tree-sitter-python => tsp}/bindings/rust/README.md | 0 .../{tree-sitter-python => tsp}/bindings/rust/build.rs | 0 .../tsg-python/{tree-sitter-python => tsp}/bindings/rust/lib.rs | 0 .../extractor/tsg-python/{tree-sitter-python => tsp}/grammar.js | 0 .../extractor/tsg-python/{tree-sitter-python => tsp}/log.html | 0 .../tsg-python/{tree-sitter-python => tsp}/package.json | 0 .../{tree-sitter-python => tsp}/queries/highlights.scm | 0 .../tsg-python/{tree-sitter-python => tsp}/queries/tags.scm | 0 .../tsg-python/{tree-sitter-python => tsp}/src/grammar.json | 0 .../tsg-python/{tree-sitter-python => tsp}/src/node-types.json | 0 .../tsg-python/{tree-sitter-python => tsp}/src/parser.c | 0 .../tsg-python/{tree-sitter-python => tsp}/src/scanner.cc | 0 .../{tree-sitter-python => tsp}/src/tree_sitter/parser.h | 0 23 files changed, 1 insertion(+), 1 deletion(-) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/.gitignore (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/.npmignore (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/BUILD.bazel (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/Cargo.toml (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/LICENSE (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/README.md (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/binding.gyp (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/bindings/node/binding.cc (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/bindings/node/index.js (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/bindings/rust/README.md (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/bindings/rust/build.rs (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/bindings/rust/lib.rs (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/grammar.js (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/log.html (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/package.json (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/queries/highlights.scm (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/queries/tags.scm (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/src/grammar.json (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/src/node-types.json (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/src/parser.c (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/src/scanner.cc (100%) rename python/extractor/tsg-python/{tree-sitter-python => tsp}/src/tree_sitter/parser.h (100%) diff --git a/python/extractor/tsg-python/Cargo.toml b/python/extractor/tsg-python/Cargo.toml index 71c5b498bae..b183aa83dcf 100644 --- a/python/extractor/tsg-python/Cargo.toml +++ b/python/extractor/tsg-python/Cargo.toml @@ -17,7 +17,7 @@ smallvec = { version="1.6", features=["union"] } thiserror = "1.0" tree-sitter = "0.20.4" tree-sitter-graph = "0.7.0" -tree-sitter-python = {path = "tree-sitter-python"} +tree-sitter-python = {path = "tsp"} clap = "2.32" [dependencies.string-interner] diff --git a/python/extractor/tsg-python/tree-sitter-python/.gitignore b/python/extractor/tsg-python/tsp/.gitignore similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/.gitignore rename to python/extractor/tsg-python/tsp/.gitignore diff --git a/python/extractor/tsg-python/tree-sitter-python/.npmignore b/python/extractor/tsg-python/tsp/.npmignore similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/.npmignore rename to python/extractor/tsg-python/tsp/.npmignore diff --git a/python/extractor/tsg-python/tree-sitter-python/BUILD.bazel b/python/extractor/tsg-python/tsp/BUILD.bazel similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/BUILD.bazel rename to python/extractor/tsg-python/tsp/BUILD.bazel diff --git a/python/extractor/tsg-python/tree-sitter-python/Cargo.toml b/python/extractor/tsg-python/tsp/Cargo.toml similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/Cargo.toml rename to python/extractor/tsg-python/tsp/Cargo.toml diff --git a/python/extractor/tsg-python/tree-sitter-python/LICENSE b/python/extractor/tsg-python/tsp/LICENSE similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/LICENSE rename to python/extractor/tsg-python/tsp/LICENSE diff --git a/python/extractor/tsg-python/tree-sitter-python/README.md b/python/extractor/tsg-python/tsp/README.md similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/README.md rename to python/extractor/tsg-python/tsp/README.md diff --git a/python/extractor/tsg-python/tree-sitter-python/binding.gyp b/python/extractor/tsg-python/tsp/binding.gyp similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/binding.gyp rename to python/extractor/tsg-python/tsp/binding.gyp diff --git a/python/extractor/tsg-python/tree-sitter-python/bindings/node/binding.cc b/python/extractor/tsg-python/tsp/bindings/node/binding.cc similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/bindings/node/binding.cc rename to python/extractor/tsg-python/tsp/bindings/node/binding.cc diff --git a/python/extractor/tsg-python/tree-sitter-python/bindings/node/index.js b/python/extractor/tsg-python/tsp/bindings/node/index.js similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/bindings/node/index.js rename to python/extractor/tsg-python/tsp/bindings/node/index.js diff --git a/python/extractor/tsg-python/tree-sitter-python/bindings/rust/README.md b/python/extractor/tsg-python/tsp/bindings/rust/README.md similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/bindings/rust/README.md rename to python/extractor/tsg-python/tsp/bindings/rust/README.md diff --git a/python/extractor/tsg-python/tree-sitter-python/bindings/rust/build.rs b/python/extractor/tsg-python/tsp/bindings/rust/build.rs similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/bindings/rust/build.rs rename to python/extractor/tsg-python/tsp/bindings/rust/build.rs diff --git a/python/extractor/tsg-python/tree-sitter-python/bindings/rust/lib.rs b/python/extractor/tsg-python/tsp/bindings/rust/lib.rs similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/bindings/rust/lib.rs rename to python/extractor/tsg-python/tsp/bindings/rust/lib.rs diff --git a/python/extractor/tsg-python/tree-sitter-python/grammar.js b/python/extractor/tsg-python/tsp/grammar.js similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/grammar.js rename to python/extractor/tsg-python/tsp/grammar.js diff --git a/python/extractor/tsg-python/tree-sitter-python/log.html b/python/extractor/tsg-python/tsp/log.html similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/log.html rename to python/extractor/tsg-python/tsp/log.html diff --git a/python/extractor/tsg-python/tree-sitter-python/package.json b/python/extractor/tsg-python/tsp/package.json similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/package.json rename to python/extractor/tsg-python/tsp/package.json diff --git a/python/extractor/tsg-python/tree-sitter-python/queries/highlights.scm b/python/extractor/tsg-python/tsp/queries/highlights.scm similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/queries/highlights.scm rename to python/extractor/tsg-python/tsp/queries/highlights.scm diff --git a/python/extractor/tsg-python/tree-sitter-python/queries/tags.scm b/python/extractor/tsg-python/tsp/queries/tags.scm similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/queries/tags.scm rename to python/extractor/tsg-python/tsp/queries/tags.scm diff --git a/python/extractor/tsg-python/tree-sitter-python/src/grammar.json b/python/extractor/tsg-python/tsp/src/grammar.json similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/src/grammar.json rename to python/extractor/tsg-python/tsp/src/grammar.json diff --git a/python/extractor/tsg-python/tree-sitter-python/src/node-types.json b/python/extractor/tsg-python/tsp/src/node-types.json similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/src/node-types.json rename to python/extractor/tsg-python/tsp/src/node-types.json diff --git a/python/extractor/tsg-python/tree-sitter-python/src/parser.c b/python/extractor/tsg-python/tsp/src/parser.c similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/src/parser.c rename to python/extractor/tsg-python/tsp/src/parser.c diff --git a/python/extractor/tsg-python/tree-sitter-python/src/scanner.cc b/python/extractor/tsg-python/tsp/src/scanner.cc similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/src/scanner.cc rename to python/extractor/tsg-python/tsp/src/scanner.cc diff --git a/python/extractor/tsg-python/tree-sitter-python/src/tree_sitter/parser.h b/python/extractor/tsg-python/tsp/src/tree_sitter/parser.h similarity index 100% rename from python/extractor/tsg-python/tree-sitter-python/src/tree_sitter/parser.h rename to python/extractor/tsg-python/tsp/src/tree_sitter/parser.h