{"id":48462464,"url":"https://github.com/cursorless-dev/talon-tools","last_synced_at":"2026-04-07T02:32:10.853Z","repository":{"id":343053551,"uuid":"1176097769","full_name":"cursorless-dev/talon-tools","owner":"cursorless-dev","description":"Linting and formatting tools for Talon and Cursorless","archived":false,"fork":false,"pushed_at":"2026-03-23T12:50:12.000Z","size":1033,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-24T07:26:53.335Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/cursorless-dev.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":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["cursorless-dev"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2026-03-08T16:04:56.000Z","updated_at":"2026-03-23T12:49:09.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/cursorless-dev/talon-tools","commit_stats":null,"previous_names":["cursorless-dev/talon-tools"],"tags_count":17,"template":false,"template_full_name":null,"purl":"pkg:github/cursorless-dev/talon-tools","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cursorless-dev%2Ftalon-tools","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cursorless-dev%2Ftalon-tools/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cursorless-dev%2Ftalon-tools/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cursorless-dev%2Ftalon-tools/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cursorless-dev","download_url":"https://codeload.github.com/cursorless-dev/talon-tools/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cursorless-dev%2Ftalon-tools/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31498069,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-06T17:22:55.647Z","status":"online","status_checked_at":"2026-04-07T02:00:07.164Z","response_time":105,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2026-04-07T02:32:10.286Z","updated_at":"2026-04-07T02:32:10.846Z","avatar_url":"https://github.com/cursorless-dev.png","language":"TypeScript","funding_links":["https://github.com/sponsors/cursorless-dev"],"categories":[],"sub_categories":[],"readme":"# Talon tools\n\nLinting and formatting tools for Talon and Cursorless.\n\n## Installation\n\n### Local dev dependency\n\nInstall the package in your project:\n\n```sh\nnpm install --save-dev @cursorless/talon-tools\n```\n\nRun the local CLI commands with `npx`:\n\n```sh\nnpx talon-fmt [options] [file/dir/glob ...]\nnpx snippet-fmt [options] [file/dir/glob ...]\nnpx tree-sitter-fmt [options] [file/dir/glob ...]\n```\n\n### Global install\n\nInstall the binaries globally:\n\n```sh\nnpm install --global @cursorless/talon-tools\n```\n\nRun the binaries directly:\n\n```sh\ntalon-fmt [options] [file/dir/glob ...]\nsnippet-fmt [options] [file/dir/glob ...]\ntree-sitter-fmt [options] [file/dir/glob ...]\n```\n\n## CLI options\n\nAll binaries support these options:\n\n| Option      | Meaning                          |\n| ----------- | -------------------------------- |\n| `--help`    | Show help                        |\n| `--version` | Show version                     |\n| `--quiet`   | Suppress non-error output        |\n| `--check`   | Check formatting without writing |\n| `--debug`   | Print debug output               |\n\nUse `--debug` when diagnosing parser or formatter support for new syntax.\n\n## Formatting options\n\nFormatting options are read from [.editorconfig](https://editorconfig.org) based on the file path being\nformatted. For stdin, the formatter resolves a synthetic file such as\n`stdin.talon`, `stdin.talon-list`, `stdin.scm`, or `stdin.snippet` from the\ncurrent working directory and loads `.editorconfig` relative to that path.\n\nSupported `.editorconfig` properties:\n\n| Property               | Meaning                             | Default  | `talon-fmt` | `snippet-fmt` | `tree-sitter-fmt` |\n| ---------------------- | ----------------------------------- | -------- | ----------- | ------------- | ----------------- |\n| `end_of_line`          | Set output line endings             | `lf`     | yes         | yes           | yes               |\n| `indent_style`         | Use tabs or spaces for indentation  | `spaces` | yes         | no            | yes               |\n| `indent_size`          | Set indentation width               | `4`      | yes         | no            | yes               |\n| `max_line_length`      | Set preferred maximum line width    | `80`     | yes         | no            | no                |\n| `insert_final_newline` | Ensure the file ends with a newline | `true`   | yes         | yes           | yes               |\n| `preserve_multiline`   | Keep existing multi-line formatting | `false`  | yes         | no            | no                |\n| `column_width`         | Set aligned left-column width       |          | yes         | no            | no                |\n\nUse `--` to mark the end of options. Any following arguments are treated as\nfile, directory, or glob patterns even if they start with `--`.\n\n```sh\ntalon-fmt -- --check\n```\n\n### Column width comment\n\nThe column width option can be enabled on a per file basis using a fmt comment.\n\n```talon\n# fmt: columnWidth=15\n\nfoo:           \"foo\"\nfoo bar baz:   \"foo bar baz\"\n```\n\n## Exit codes\n\n| Code | Information                         |\n| ---- | ----------------------------------- |\n| 0    | Everything formatted properly       |\n| 1    | Something wasn't formatted properly |\n| 2    | Runtime error                       |\n\n## Pre commit\n\n```yaml\nrepos:\n  - repo: https://github.com/cursorless-dev/talon-tools\n    rev: v0.10.0\n    hooks:\n      - id: talon-fmt\n      - id: snippet-fmt\n      - id: tree-sitter-fmt\n```\n\n## Guidelines\n\n- Each pre-commit hook should have a matching npm binary with the same name.\n- Binaries ending with `-fmt` are formatters by default and turn into linters/checkers with the `--check` argument.\n- (Future) binaries ending with `-check` are linters by default and turn into fixers with the `--fix` argument.\n\n## Developer\n\n```sh\n# Try formatter without pre-commit\nnode dist/talonFormatter.js test.talon\n\n# Try formatter with pre-commit\npre-commit try-repo . talon-fmt --files test.talon -v\n```\n\nInstall the hooks locally:\n\n```yaml\n# .pre-commit-config.yaml\nrepos:\n  - repo: .\n    rev: HEAD\n    hooks:\n      - id: talon-fmt\n      - id: snippet-fmt\n      - id: tree-sitter-fmt\n```\n\n```sh\npre-commit install\npre-commit run --all-files\n```\n\n## Release\n\nWhen creating a new release do the following:\n\n- Update version in [`package.json`](./package.json)\n- Update version in [`README.md`](./README.md#pre-commit)\n- Run build: `npm run build`\n- Add new tag eg `git tag v1.2.0`\n- Publish lib: `npm publish --access public`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcursorless-dev%2Ftalon-tools","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcursorless-dev%2Ftalon-tools","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcursorless-dev%2Ftalon-tools/lists"}