{"id":19516794,"url":"https://github.com/chardoncs/zig-ansi-parse","last_synced_at":"2025-02-26T00:12:00.133Z","repository":{"id":260744787,"uuid":"881223567","full_name":"chardoncs/zig-ansi-parse","owner":"chardoncs","description":"Comptime-proof ANSI format parsing library for Zig","archived":false,"fork":false,"pushed_at":"2025-01-05T03:42:55.000Z","size":45,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-23T10:42:27.120Z","etag":null,"topics":["ansi-code","ansi-colors","ansi-terminal","colorization","parser","zig","ziglang"],"latest_commit_sha":null,"homepage":"","language":"Zig","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/chardoncs.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-10-31T06:17:49.000Z","updated_at":"2025-01-01T01:35:18.000Z","dependencies_parsed_at":null,"dependency_job_id":"0ef4a6c5-e8b1-447a-a309-66a352082d63","html_url":"https://github.com/chardoncs/zig-ansi-parse","commit_stats":{"total_commits":51,"total_committers":1,"mean_commits":51.0,"dds":0.0,"last_synced_commit":"eb454e3748ac77abf59f7ea8a4c15b423964f8ac"},"previous_names":["chardoncs/zig-ansi-parse"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chardoncs%2Fzig-ansi-parse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chardoncs%2Fzig-ansi-parse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chardoncs%2Fzig-ansi-parse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chardoncs%2Fzig-ansi-parse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chardoncs","download_url":"https://codeload.github.com/chardoncs/zig-ansi-parse/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240766621,"owners_count":19854119,"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":["ansi-code","ansi-colors","ansi-terminal","colorization","parser","zig","ziglang"],"created_at":"2024-11-11T00:00:50.856Z","updated_at":"2025-02-26T00:12:00.071Z","avatar_url":"https://github.com/chardoncs.png","language":"Zig","readme":"# zig-ansi-parse\n\nComptime-proof ANSI format parsing library for Zig.\n\n[How it works?](https://github.com/chardoncs/zig-ansi-parse/wiki/Syntax)\n\n## Install\n\n1. Fetch it in your project, `\u003cversion\u003e` is the version you want\n\n```bash\nzig fetch --save https://github.com/chardoncs/zig-ansi-parse/archive/refs/tags/v\u003cversion\u003e.tar.gz\n```\n\nOr fetch the git repo for latest updates\n\n```bash\nzig fetch --save git+https://github.com/chardoncs/zig-ansi-parse\n```\n\n2. Configure your `build.zig`.\n\n```zig\nconst ansi_parse = b.dependency(\"ansi-parse\", .{});\nexe.root_module.addImport(\"ansi-parse\", ansi_parse.module(\"ansi-parse\"));\n```\n\n## At a glance\n\n```zig\nconst std = @import(\"std\");\nconst parseComptime = @import(\"ansi-parse\").parseComptime;\n\nconst demo_text = parseComptime(\n    \\\\\u003cCYAN\u003eGreetings!\u003c/\u003e I'm \u003cB\u003ebold\u003c/\u003e and \u003cBLUE;B\u003eblue\u003c/\u003e\n    \\\\\u003cNYAN\u003eIgnore this\u003c/\u003e\n    \\\\\\\u003cescaped\u003e\n    \\\\\u003c!TAB\u003etabbed\u003c!LF\u003eOllal\u003c!CR\u003eHello\n    \\\\\u003c!TAB*3\u003eThree tabs\n    \\\\\n, .{} // Options\n);\n\npub fn main() !void {\n    std.debug.print(demo_text, .{});\n}\n```\n\n## Options\n\n|     Name     |  Default value  |        Description      |\n|--------------|-----------------|-------------------------|\n| branch_quota | 200,000         | (Comptime only) Evaluation branch quota. A larger quota can prevent the compiler from giving up caused by loops |\n| out_size     | `input.len * 4` | (Comptime only) Capacity of the output string, set a larger value if the output is truncated |\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchardoncs%2Fzig-ansi-parse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchardoncs%2Fzig-ansi-parse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchardoncs%2Fzig-ansi-parse/lists"}