Skip to main content

tree-sitter-gosu

License: MIT Version

A Tree-sitter grammar that parses Gosu, a statically typed, JVM-based general-purpose programming language.

Requirements

  • Python >=3.14
  • Poetry 2.2
  • Node.js (for tree-sitter-cli, used to regenerate the parser from grammar.js)
  • A C compiler (MSVC on Windows, GCC/Clang on Linux/macOS) to build the native extension and run tree-sitter test/tree-sitter parse

Installation

poetry install

Usage

import tree_sitter
import tree_sitter_gosu

language = tree_sitter.Language(tree_sitter_gosu.language())
parser = tree_sitter.Parser(language)
tree = parser.parse(b"class Foo { function bar(): int { return 1 } }")

Development

Install dependencies

poetry install

Run tests with coverage

poetry run pytest --cov=tree_sitter_gosu tests --cov-report html

Format and lint

poetry run black tree_sitter_gosu; poetry run pylint tree_sitter_gosu

Regenerate the parser from grammar.js

npm install
npx tree-sitter generate
npx tree-sitter test

Configuration

Set the TREE_SITTER_GOSU_CONFIG_DIR environment variable to override the default configuration directory.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Release files for tree-sitter-gosu 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tree-sitter-gosu 0.1.2
File Size Uploaded
tree_sitter_gosu-0.1.2.tar.gz 138.6 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for tree-sitter-gosu 0.1.2
File Interpreter ABI Platform
tree_sitter_gosu-0.1.2-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
tree_sitter_gosu-0.1.2-cp314-cp314-manylinux_2_39_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.39+ x86-64 Details
tree_sitter_gosu-0.1.2-cp314-cp314-macosx_26_0_arm64.whl CPython 3.14 CPython 3.14 macOS 26.0+ ARM64 Details

Total release size: 341.2 kB

Release files / tree_sitter_gosu-0.1.2.tar.gz

Download URL tree_sitter_gosu-0.1.2.tar.gz
Size 138.6 kB
Tags Source
SHA-256 checksum
How to use checksums
933d64e3faf8d986be7c8e064462fa259eb0f47555ab3f033360dbd3ccc6d0bc
BLAKE2b-256 checksum
How to use checksums
4d5ce2931e50163f5a9784365983df11d1c1a901c7be64973acd41e2ed853935
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / tree_sitter_gosu-0.1.2-cp314-cp314-win_amd64.whl

Download URL tree_sitter_gosu-0.1.2-cp314-cp314-win_amd64.whl
Size 48.1 kB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
8ca096c415cb0a7c1d0333b824de2db702fb84da3a65ebd06ed942598992bdde
BLAKE2b-256 checksum
How to use checksums
62c3bcc86cd2aad5502629143ad2432671b9a79c06b42625ccd8af18c305b7d1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / tree_sitter_gosu-0.1.2-cp314-cp314-manylinux_2_39_x86_64.whl

Download URL tree_sitter_gosu-0.1.2-cp314-cp314-manylinux_2_39_x86_64.whl
Size 67.6 kB
Tags CPython 3.14 Linux glibc 2.39+ x86-64
SHA-256 checksum
How to use checksums
35af523d89b124c31aa45d8d02af8055b2987b85d085ae33ae31bf322404f4ba
BLAKE2b-256 checksum
How to use checksums
dc49d07a88e8dbf10350673c0092a2fac3c1e92e6be9dfef4df87121758cbb4a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / tree_sitter_gosu-0.1.2-cp314-cp314-macosx_26_0_arm64.whl

Download URL tree_sitter_gosu-0.1.2-cp314-cp314-macosx_26_0_arm64.whl
Size 86.9 kB
Tags CPython 3.14 macOS 26.0+ ARM64
SHA-256 checksum
How to use checksums
9b59314e1cd1327b33de9979feb787b69098074dacc259dbf460846fca12c4cf
BLAKE2b-256 checksum
How to use checksums
804d4ec174c1f2d6a2e9a22e10dcd38b29e12a9aa2310b29c55cb1f77716e087
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release history Release notifications | RSS feed

0.2.0

4 release files

This release

0.1.2 This release

4 release files

0.1.1

4 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page