Skip to main content

Pact grammar for tree-sitter

Project description

tree-sitter-pact

tree-sitter grammar for pact smart contract language

Neovim setup (WIP)

I will create a PR to add this to the official nvim-treesitter repo once it's ready, for now you can use it by following these steps:

Clone the repo

git clone https://github.com/kadena-community/tree-sitter-pact.git

Add those to your init.lua

vim.filetype.add({
  extension = {
    pact = "pact",
    repl = "pact",
  },
})
local parser_config = require("nvim-treesitter.parsers").get_parser_configs()
parser_config.pact = {
  install_info = {
    url = "~/path/to/c/tree-sitter-pact",
    files = { "src/parser.c" },
  },
  filetype = "pact",
}

Then run :TSInstall pact in neovim.

also you need to link the queries folder to your nvim config folder

mkdir -p ~/.config/nvim/after/queries/pact
ln ./queries/highlights.scm ~/.config/nvim/after/queries/pact/highlights.scm
ln ./queries/locals.scm ~/.config/nvim/after/queries/pact/locals.scm
ln ./queries/textobjects.scm ~/.config/nvim/after/queries/pact/textobjects.scm
ln ./queries/folds.scm ~/.config/nvim/after/queries/pact/folds.scm
ln ./queries/indents.scm ~/.config/nvim/after/queries/pact/indents.scm

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tree_sitter_pact-0.0.1.tar.gz (29.1 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

tree_sitter_pact-0.0.1-cp39-abi3-win_arm64.whl (24.4 kB view details)

Uploaded CPython 3.9+Windows ARM64

tree_sitter_pact-0.0.1-cp39-abi3-win_amd64.whl (25.9 kB view details)

Uploaded CPython 3.9+Windows x86-64

tree_sitter_pact-0.0.1-cp39-abi3-musllinux_1_2_x86_64.whl (39.6 kB view details)

Uploaded CPython 3.9+musllinux: musl 1.2+ x86-64

tree_sitter_pact-0.0.1-cp39-abi3-musllinux_1_2_aarch64.whl (42.3 kB view details)

Uploaded CPython 3.9+musllinux: musl 1.2+ ARM64

tree_sitter_pact-0.0.1-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (42.8 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

tree_sitter_pact-0.0.1-cp39-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (43.0 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

tree_sitter_pact-0.0.1-cp39-abi3-macosx_11_0_arm64.whl (23.4 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

tree_sitter_pact-0.0.1-cp39-abi3-macosx_10_9_x86_64.whl (23.6 kB view details)

Uploaded CPython 3.9+macOS 10.9+ x86-64

File details

Details for the file tree_sitter_pact-0.0.1.tar.gz.

File metadata

  • Download URL: tree_sitter_pact-0.0.1.tar.gz
  • Upload date:
  • Size: 29.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.6

File hashes

Hashes for tree_sitter_pact-0.0.1.tar.gz
Algorithm Hash digest
SHA256 518c9e6e12a8ca9e7f73c0951ff3a1a92ecc2a73ad530eefb216573e1cb83cd3
MD5 70b51f779f6daea6a96351e40d394d63
BLAKE2b-256 d63c26d7bfe2f157a1c8026b100b14bb8303cbce03f5b362c1c75fee068705ca

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-win_arm64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-win_arm64.whl
Algorithm Hash digest
SHA256 34782b7d227c95a63f90cbfd79a732e4a478b87161982e04b1aaa126836c3b5e
MD5 7875611cdac48fa001da3b1e8fb28e96
BLAKE2b-256 c19d752a8630a074c895316c545ab0a9b6a407f36dd564607c21081c5c31fbe3

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 1d23353d434353aeeb4122025dbc7005806ff61b58e4170b220b8bf315317505
MD5 4ce30c7a45b65542b09b4e41c6c4b8a5
BLAKE2b-256 5cde16e72c486978476a714771d4111b65a0638747d06cfd033da935df418864

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 332e605df68008a696bb3a40df29c477b0f66b4de99dc279b3c6a1924e33264b
MD5 5f4393adce1b8c71feeb772265c11c5a
BLAKE2b-256 acc1663aa290f443777bd2515c35112bcba190e15e7861fee3c00189ca287175

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 2bf3a3142260cfe1f8c431bb905890a497e0496f496b8ab2d97f687520419d8d
MD5 5b9eea7875d7991f4bb242fce8f3d496
BLAKE2b-256 5e9eafc6b3b6ccdb044b7aa0994af569780a974c3cde8047100ac9e7ab432492

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 9b7a8cfcb52ad98456c6f767f4ceb6c3a6d014db7c7a040f6719184abd2a5106
MD5 f6370db04368d2c4807197afd2d9320c
BLAKE2b-256 0b363036bbe866610c6d31b5984609bc823127c7b74185752d7e5069e38518a2

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b3f007ff9cbf02d8762048b6f47b13dcdbd26bc7addccb65e309efc7b8763802
MD5 a48253fb0d7b8dff2662d1b7e99aa61f
BLAKE2b-256 6980c0818d0124d14d34740ea34378bb39c12d166bf48c1bdca8829c34b3056a

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 571c13a4bc73f959497187375ee9a7cc780588cb29103021ce2639bf93366a24
MD5 4a104532855a9c9a455c01b55b745f24
BLAKE2b-256 2b2e477da2ca68e8676b1ef37d82a5abc323c9b7c215f51fe435b13bce9220a4

See more details on using hashes here.

File details

Details for the file tree_sitter_pact-0.0.1-cp39-abi3-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_pact-0.0.1-cp39-abi3-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 51b7057b329bd9bf8d57ae95c114ec09e8ee28743e2c3140186c148d72c65577
MD5 6ab9aeb2c3c2d52be929e29a71b2eec0
BLAKE2b-256 e49561ca323850c4d22599b836c43a3424950b1b71621e9c09ec2e6d6f102fff

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page