{"id":23613586,"url":"https://github.com/bezhermoso/tree-sitter-ghostty","last_synced_at":"2025-11-06T09:30:28.803Z","repository":{"id":269920900,"uuid":"908792865","full_name":"bezhermoso/tree-sitter-ghostty","owner":"bezhermoso","description":"Tree-sitter grammar for Ghostty configuration files","archived":false,"fork":false,"pushed_at":"2025-02-07T06:30:20.000Z","size":247,"stargazers_count":21,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-07T07:26:55.437Z","etag":null,"topics":["ghostty","neovim-plugin","tree-sitter","tree-sitter-grammar","tree-sitter-parser"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bezhermoso.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-27T01:39:35.000Z","updated_at":"2025-02-07T06:30:24.000Z","dependencies_parsed_at":"2024-12-27T07:24:50.654Z","dependency_job_id":"f94f8b7c-884c-4e27-b6a5-464facc8befe","html_url":"https://github.com/bezhermoso/tree-sitter-ghostty","commit_stats":null,"previous_names":["bezhermoso/tree-sitter-ghostty"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezhermoso%2Ftree-sitter-ghostty","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezhermoso%2Ftree-sitter-ghostty/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezhermoso%2Ftree-sitter-ghostty/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bezhermoso%2Ftree-sitter-ghostty/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bezhermoso","download_url":"https://codeload.github.com/bezhermoso/tree-sitter-ghostty/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239488574,"owners_count":19647234,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["ghostty","neovim-plugin","tree-sitter","tree-sitter-grammar","tree-sitter-parser"],"created_at":"2024-12-27T17:18:06.152Z","updated_at":"2025-11-06T09:30:28.752Z","avatar_url":"https://github.com/bezhermoso.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tree-sitter-ghostty\n\n\u003cdiv align=\"center\"\u003e\n    \u003cdiv\u003e\n        \u003ca href=\"https://github.com/bezhermoso/tree-sitter-ghostty/actions/workflows/ci.yml\"\u003e\n            \u003cimg src=\"https://github.com/bezhermoso/tree-sitter-ghostty/actions/workflows/ci.yml/badge.svg\"\u003e\n        \u003c/a\u003e\n    \u003c/div\u003e\n    \u003cbr\u003e\n    \u003cimg width=\"250\" src=\"https://github.com/user-attachments/assets/8d4d3b38-cc03-46e6-9198-85c052ade348\" align=\"center\" /\u003e\n    \u003cdiv\u003e\n    \u003cbr\u003e\n        \u003cp\u003e\n        Tree-sitter grammar for \u003ca href=\"https://ghostty.org\"\u003eGhostty\u003c/a\u003e configuration files\n        \u003c/p\u003e\n    \u003c/div\u003e\n\u003c/div\u003e\n\n\u003cimg width=\"973\" alt=\"SCR-20241229-moju\" src=\"https://github.com/user-attachments/assets/1de7cced-b798-4b6c-a847-6936c76d8188\" /\u003e\n\u003chr\u003e\n\u003cimg width=\"973\" alt=\"SCR-20241229-mogq\" src=\"https://github.com/user-attachments/assets/f6a78843-3ef0-479e-b4dc-2268a2b61ce9\" /\u003e\n\n\n\n## TODOs\n\n- Grammar\n    - [x] Comments\n    - [x] Raw values\n    - [x] Numbers\n    - [x] Percents\n    - [x] Colors \n    - [x] Palette\n    - [x] Keybindings\n        - [x] Chords\n        - [x] Modifiers\n        - [x] Actions \u0026 arguments\n        - [x] Special keys (e.g. `tab`, `space`, `up`)\n- [x] Tests\n- [x] Capture highlight groups\n- [x] Stable release\n    - [ ] Contribute queries to [nvim-treesitter] (No longer accepting experimental parsers)\n\n\n## Neovim\n\n### lazy.nvim\n\nAdd this:\n\n```lua\n{\n    \"bezhermoso/tree-sitter-ghostty\",\n    build = \"make nvim_install\",\n}\n```\n\n\u003e [!NOTE]\n\u003e Having [nvim-treesitter] installed is not required. However if you have it installed, this plugin will attempt to register\n\u003e itself as a parser so that `nvim-treesitter` can manage it e.g. `:TSInstall! ghostty`.\n\nInstalling this as a plugin should automatically enable syntax highlighting for Ghostty configuration files located in\nexpected paths. You can add this line to the top of your config file if its filetype is not detected automatically:\n\n```diff\n+# vim: ft=ghostty\n #\n # The rest of your Ghostty configuration 👻...\n```\n\n## Helix\n\nThis grammar is now included in upstream Helix: https://github.com/helix-editor/helix, however if you do not current have highlighting, you can set it up manually using the following steps:\n\n1. Add this to your `languages.toml`\n\n```toml\n[[language]]\nname = \"ghostty\"\nscope = \"source.ghostty\"\nfile-types = [{ glob = \"ghostty/config\" }]\ncomment-tokens = \"#\"\nindent = { tab-width = 2, unit = \"  \" }\n\n[[grammar]]\nname = \"ghostty\"\nsource = { git = \"https://github.com/bezhermoso/tree-sitter-ghostty\" , rev = \"8438a93b44367e962b2ea3a3b6511885bebd196a\" }\n```\n\n2. Download the ghostty [highlight queries from upstream](https://github.com/helix-editor/helix/blob/master/runtime/queries/ghostty/highlights.scm) and install them into the Helix runtime directory (located in config): `runtime/queries/ghostty/highlights.scm`\n\n3. Build and fetch the grammar\n```\n    hx -g fetch \u0026\u0026 hx -g build\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbezhermoso%2Ftree-sitter-ghostty","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbezhermoso%2Ftree-sitter-ghostty","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbezhermoso%2Ftree-sitter-ghostty/lists"}