{"id":16138192,"url":"https://github.com/frozolotl/typst-ansi-hl","last_synced_at":"2026-03-07T05:06:45.656Z","repository":{"id":219643869,"uuid":"749528920","full_name":"frozolotl/typst-ansi-hl","owner":"frozolotl","description":"typst-ansi-hl highlights your Typst code","archived":false,"fork":false,"pushed_at":"2026-01-24T19:36:08.000Z","size":77,"stargazers_count":14,"open_issues_count":1,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-25T08:31:55.158Z","etag":null,"topics":["ansi","cli","discord","tools","typst"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"eupl-1.2","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/frozolotl.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,"zenodo":null}},"created_at":"2024-01-28T20:42:16.000Z","updated_at":"2026-01-24T19:36:12.000Z","dependencies_parsed_at":"2024-02-22T00:25:53.676Z","dependency_job_id":"2d7f910e-4301-4219-a283-22e008feaf0a","html_url":"https://github.com/frozolotl/typst-ansi-hl","commit_stats":null,"previous_names":["frozolotl/typst2ansi"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/frozolotl/typst-ansi-hl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frozolotl%2Ftypst-ansi-hl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frozolotl%2Ftypst-ansi-hl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frozolotl%2Ftypst-ansi-hl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frozolotl%2Ftypst-ansi-hl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/frozolotl","download_url":"https://codeload.github.com/frozolotl/typst-ansi-hl/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frozolotl%2Ftypst-ansi-hl/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30208730,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T03:24:23.086Z","status":"ssl_error","status_checked_at":"2026-03-07T03:23:11.444Z","response_time":53,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6: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":["ansi","cli","discord","tools","typst"],"created_at":"2024-10-09T23:32:48.613Z","updated_at":"2026-03-07T05:06:45.598Z","avatar_url":"https://github.com/frozolotl.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# typst-ansi-hl\ntypst-ansi-hl highlights your Typst code using ANSI escape sequences.\n\nIt is especially intended to be used to provide the otherwise missing Typst syntax highlighting in Discord.\n\n## Installation\n```sh\ncargo install --path .\n```\n\n## Usage\nSimply run `typst-ansi-hl main.typ` or pipe the source code into `typst-ansi-hl`.\nSee [Clipboard-based Workflow](#clipboard-based-workflow) for information on how to copy Discord-compatible output to your clipboard.\n\n```\nUsage: typst-ansi-hl [OPTIONS] [INPUT]\n\nArguments:\n  [INPUT]\n          The input path. If unset, stdin is used\n\nOptions:\n  -d, --discord\n          Wrap the output in a Discord-flavoured-markdown–style ANSI codeblock\n\n  -D, --no-discord\n          Don't wrap the output in a markdown-style codeblock. [default]\n\n  -s, --strip-ansi\n          Strip all ANSI escape sequences from the input before processing. [default]\n\n  -S, --no-strip-ansi\n          Don't remove escape sequences from the input\n\n  -c, --unwrap-codeblock\n          If the input is surrounded by an ANSI codeblock as generated by this tool, remove it\n\n  -C, --no-unwrap-codeblock\n          Don't remove surrounding codeblock from the input. [default]\n\n  -u, --unindent\n          Strip any top-level indentation in the input prior to highlighting it\n\n  -U, --no-unindent\n          Keep indents as-is. [default]\n\n  -l, --soft-limit \u003cSOFT_LIMIT\u003e\n          Softly enforce a byte size limit.\n\n          This means that if the size limit is exceeded, less colors are used in order to get below that size limit. If it is not possible to get below that limit, the text is printed anyway.\n\n  -m, --mode \u003cMODE\u003e\n          The kind of input syntax\n\n          [default: markup]\n          [possible values: code, markup, math]\n\n  -h, --help\n          Print help (see a summary with '-h')\n```\n\n### Clipboard-based Workflow\nYou can bind one of the following commands to a certain key bind for improved ease-of-use:\n```sh\n# Linux X11 (Bash/Zsh/Fish/Nushell)\nxclip -selection clipboard -out | typst-ansi-hl --discord --soft-limit 2000 | xclip -selection clipboard -in\n\n# Linux Wayland (Bash/Zsh/Fish/Nushell)\nwl-paste | typst-ansi-hl --discord --soft-limit 2000 | wl-copy --type text/markdown\n\n# Windows (PowerShell)\nGet-Clipboard | typst-ansi-hl --discord --soft-limit 2000 | Set-Clipboard\n```\n\n### Library\nYou can also use this crate as a library.\nSee the [documentation](https://docs.rs/typst-ansi-hl/latest) for further details.\n\n## Legal\nThis software is not affiliated with Typst, the brand.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrozolotl%2Ftypst-ansi-hl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffrozolotl%2Ftypst-ansi-hl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrozolotl%2Ftypst-ansi-hl/lists"}