{"id":29012086,"url":"https://github.com/liblouis/tree-sitter-liblouis","last_synced_at":"2026-04-28T01:31:46.290Z","repository":{"id":57379617,"uuid":"437909891","full_name":"liblouis/tree-sitter-liblouis","owner":"liblouis","description":"A tree-sitter parser for liblouis tables","archived":false,"fork":false,"pushed_at":"2022-01-04T11:58:01.000Z","size":134,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-29T18:54:16.920Z","etag":null,"topics":["liblouis","parser","tree-sitter"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"isc","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/liblouis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-12-13T14:43:22.000Z","updated_at":"2022-01-04T11:57:50.000Z","dependencies_parsed_at":"2022-09-02T21:22:50.521Z","dependency_job_id":null,"html_url":"https://github.com/liblouis/tree-sitter-liblouis","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/liblouis/tree-sitter-liblouis","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Ftree-sitter-liblouis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Ftree-sitter-liblouis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Ftree-sitter-liblouis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Ftree-sitter-liblouis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liblouis","download_url":"https://codeload.github.com/liblouis/tree-sitter-liblouis/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Ftree-sitter-liblouis/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32362780,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T20:07:02.737Z","status":"ssl_error","status_checked_at":"2026-04-27T20:07:00.910Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["liblouis","parser","tree-sitter"],"created_at":"2025-06-25T18:10:43.654Z","updated_at":"2026-04-28T01:31:46.269Z","avatar_url":"https://github.com/liblouis.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Tree-sitter for liblouis tables\n\nA [Tree-sitter parser][] for liblouis tables.\n\nThis can serve as a way to support structural editing, syntax checks\nand highlighting for [liblouis][] braille tables in any editor that\nsupports tree-sitter (currently [Atom][], possibly [neovim][] and\n[Emacs][]).\n\nIt can also be used as a basis for a parser for the liblouis tables\nalthough personally I would prefer a Rust native solution such as\n[nom][] or [pest][].\n\n[Tree-sitter parser]: https://tree-sitter.github.io/tree-sitter/\n[liblouis]: https://github.com/liblouis/liblouis\n[Atom]: https://atom.io/\n[neovim]: https://neovim.io/\n[Emacs]: https://www.gnu.org/software/emacs/\n[nom]: https://github.com/Geal/nom\n[pest]: https://github.com/pest-parser/pest\n\n# Install\n\n``` console\nnpm install tree-sitter-liblouis\n```\n\n# Build\n\n``` console\nnpm install\nexport PATH=$PATH:./node_modules/.bin\ntree-sitter generate\n```\n\nTo run the test suite\n\n``` console\ntree-sitter test\n```\n\n# Usage\n\n## Parsing\n\n``` console\ntree-sitter parse '/path/to/liblouis/tables/*' --quiet --stat\n```\n\nTo get the syntax tree for a particular table\n\n``` console\ntree-sitter parse /path/to/liblouis/tables/nl-NL-g0.utb\n```\n\nYou can even get an XML export of the syntax tree\n\n``` console\ntree-sitter parse /path/to/liblouis/tables/nl-NL-g0.utb --xml\n```\n\nFor more info consult the help with `tree-sitter parse --help`.\n\n## Highlighting\n\nYou can use tree-sitter to highlight the source code of a liblouis\ntable. You need to set up your [per-user configuration][] for this to\nwork.\n\n``` console\ntree-sitter highlight ~/src/liblouis/tables/da-dk-g28.ctb\n```\n\nAgain, consult the help with `tree-sitter highlight --help`. You can for\nexample generate a highlighted HTML document\n\n``` console\ntree-sitter highlight ~/src/liblouis/tables/da-dk-g28.ctb --html \u003e da-dk-g28.html\n```\n\nTo get feel how this looks using the [standard theme][] look at the\ngenerated [da-dk-g28.html][].\n\n[per-user configuration]: https://tree-sitter.github.io/tree-sitter/syntax-highlighting#per-user-configuration\n[standard theme]: https://tree-sitter.github.io/tree-sitter/syntax-highlighting#theme\n[da-dk-g28.html]: examples/da-dk-g28.html\n\n# Status\n\nAs of this date the parser handles all liblouis tables except for\n`ja-kantenji.utb` and `ko-chars.cti`. There seems be a problem with\nsome Hangul and Han characters.\n\nI had hoped this would be immediately applicable in a wide range of\neditors. But it appears that not that many support tree-sitter yet.\nEmacs has a [tree-sitter package][]. But it still needs some manual\ntweaking to make it recognize the liblouis tree-sitter.\n\n[tree-sitter package]: https://github.com/emacs-tree-sitter/elisp-tree-sitter\n\n# Acknowledgements\n\nThe grammar is pretty much just a port of the [EBNF grammar][] in\n[rewrite-louis][], which in turn is a just port of the [Parsing\nexpression grammar][] from [louis-parser][].\n\n[EBNF grammar]: https://en.wikipedia.org/wiki/Extended_Backus%E2%80%93Naur_form\n[rewrite-louis]: https://github.com/liblouis/rewrite-louis\n[Parsing expression grammar]: https://en.wikipedia.org/wiki/Parsing_expression_grammar\n[louis-parser]: https://github.com/liblouis/louis-parser\n\n# License\n\nCopyright (C) 2021 Swiss Library for the Blind, Visually Impaired and\nPrint Disabled\n\nPermission to use, copy, modify, and/or distribute this software for any\npurpose with or without fee is hereby granted, provided that the above\ncopyright notice and this permission notice appear in all copies.\n\nTHE SOFTWARE IS PROVIDED \\\"AS IS\\\" AND THE AUTHOR DISCLAIMS ALL\nWARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES\nOF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE\nFOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY\nDAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER\nIN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING\nOUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliblouis%2Ftree-sitter-liblouis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliblouis%2Ftree-sitter-liblouis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliblouis%2Ftree-sitter-liblouis/lists"}