{"id":13446767,"url":"https://github.com/owenthereal/ccat","last_synced_at":"2025-04-13T13:14:19.042Z","repository":{"id":31575529,"uuid":"35140287","full_name":"owenthereal/ccat","owner":"owenthereal","description":"Colorizing `cat`","archived":false,"fork":false,"pushed_at":"2022-09-05T17:44:40.000Z","size":2621,"stargazers_count":3183,"open_issues_count":38,"forks_count":120,"subscribers_count":40,"default_branch":"master","last_synced_at":"2025-04-09T22:24:23.517Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://github.com/owenthereal/ccat","language":"Go","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/owenthereal.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":"2015-05-06T05:00:17.000Z","updated_at":"2025-04-09T02:54:42.000Z","dependencies_parsed_at":"2022-07-18T22:01:22.572Z","dependency_job_id":null,"html_url":"https://github.com/owenthereal/ccat","commit_stats":null,"previous_names":["jingweno/ccat"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owenthereal%2Fccat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owenthereal%2Fccat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owenthereal%2Fccat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/owenthereal%2Fccat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/owenthereal","download_url":"https://codeload.github.com/owenthereal/ccat/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248565092,"owners_count":21125418,"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":[],"created_at":"2024-07-31T05:00:59.252Z","updated_at":"2025-04-13T13:14:19.014Z","avatar_url":"https://github.com/owenthereal.png","language":"Go","funding_links":["https://opencollective.com/ccat","https://opencollective.com/ccat/backer/0/website","https://opencollective.com/ccat/backer/1/website","https://opencollective.com/ccat/backer/2/website","https://opencollective.com/ccat/backer/3/website","https://opencollective.com/ccat/backer/4/website","https://opencollective.com/ccat/backer/5/website","https://opencollective.com/ccat/backer/6/website","https://opencollective.com/ccat/backer/7/website","https://opencollective.com/ccat/backer/8/website","https://opencollective.com/ccat/backer/9/website","https://opencollective.com/ccat/backer/10/website","https://opencollective.com/ccat/backer/11/website","https://opencollective.com/ccat/backer/12/website","https://opencollective.com/ccat/backer/13/website","https://opencollective.com/ccat/backer/14/website","https://opencollective.com/ccat/backer/15/website","https://opencollective.com/ccat/backer/16/website","https://opencollective.com/ccat/backer/17/website","https://opencollective.com/ccat/backer/18/website","https://opencollective.com/ccat/backer/19/website","https://opencollective.com/ccat/backer/20/website","https://opencollective.com/ccat/backer/21/website","https://opencollective.com/ccat/backer/22/website","https://opencollective.com/ccat/backer/23/website","https://opencollective.com/ccat/backer/24/website","https://opencollective.com/ccat/backer/25/website","https://opencollective.com/ccat/backer/26/website","https://opencollective.com/ccat/backer/27/website","https://opencollective.com/ccat/backer/28/website","https://opencollective.com/ccat/backer/29/website"],"categories":["Go","Command Line","命令行工具","Command Line Utilities","System Utilities","\u003ca name=\"viewers\"\u003e\u003c/a\u003eViewers"],"sub_categories":["Dependency Management","Tools","Directory Navigation"],"readme":"# ccat\n[![OpenCollective](https://opencollective.com/ccat/backers/badge.svg)](#backers) \n[![OpenCollective](https://opencollective.com/ccat/sponsors/badge.svg)](#sponsors)\n\n`ccat` is the colorizing `cat`. It works similar to `cat` but displays content with syntax highlighting.\n\n## Supported Languages\n\n* JavaScript\n* Java\n* Ruby\n* Python\n* Go\n* C\n* JSON\n\n## Installation\n\n### OSX\n\n```\n$ brew install ccat\n```\n\n### Arch Linux\n\n```\n$ pacaur -S ccat\n$ pacaur -S ccat-git\n```\nThe ccat package will reflect the current release snapshot, while the ccat-git will be based on the current source available in the master branch of the git repo. You can use any AUR helper in place of pacaur [AUR Helpers](https://wiki.archlinux.org/index.php/AUR_helpers)\n\n### Standalone\n\n`ccat` can be easily installed as an executable.\nDownload the latest [compiled binaries](https://github.com/owenthereal/ccat/releases) and put it in your executable path.\n\n### From source\n\nPrerequisites:\n- [Git](http://git-scm.com/book/en/v2/Getting-Started-Installing-Git)\n- [Go](https://golang.org/doc/install) 1.4+\n\n```\n$ go get -u github.com/owenthereal/ccat\n```\n\n## Completion (ZSH Only)\n\n### Installation\nMove the `_ccat` file in `./completions/zsh` to your site-functions directory usually in `/usr/local/share/zsh/site-functions` or in `/usr/share/zsh/site-functions`. If completions don't work on the next ZSH startup, you can delete the file `.zcompdump` (which caches autocomplete commands) and it is usually in the home directory.\n### Uninstallation\nGo back to the directory you copied `_ccat` to and delete the file, then simply delete `.zcompdump` in order to stop errors when trying to use `ccat` autocomplete afterwards.\n\n## Usage\n\n```\n$ ccat FILE1 FILE2 ...\n$ ccat FILE1 FILE2 ... --html # output in HTML\n$ ccat --bg=dark FILE1 FILE 2 ... # dark background\n$ ccat -G String=\"_darkblue_\" -G Plaintext=\"darkred\" FILE # set color codes\n$ ccat --palette # show palette\n$ ccat # read from standard input\n$ curl https://raw.githubusercontent.com/owenthereal/ccat/master/main.go | ccat\n```\n\nIt's recommended to alias `ccat` to `cat`:\n\n```\nalias cat=ccat\n```\n\nThe overhead of `ccat` comparing to `cat` is mimimum:\n\n```\n$ wc -l main.go\n123 main.go\n$ time cat main.go \u003e /dev/null\ncat main.go \u003e /dev/null  0.00s user 0.00s system 61% cpu 0.005 total\n$ time ccat main.go \u003e /dev/null\nccat main.go \u003e /dev/null  0.00s user 0.00s system 78% cpu 0.007 total\n```\n\nYou can always invoke `cat` after aliasing `ccat` by typing `\\cat`.\n\n## Demo\n\n[![demo](https://asciinema.org/a/21858.png)](https://asciinema.org/a/21858)\n\n## Roadmap\n\n- [ ] nicer default color scheme\n- [ ] ?\n\n## Alternatives\n\n`ccat` is designed to be distributed in one binary, run at native speed\nand follow the POSIX standards. There're alternatives out there.\nUse them at your own risk :):\n\n* [pygments](http://pygments.org/)\n* [source-highlight](https://www.gnu.org/software/src-highlite/)\n\n## License\n\n[MIT](https://github.com/owenthereal/ccat/blob/master/LICENSE)\n\n## Credits\n\nThanks to [Sourcegraph](https://github.com/sourcegraph) who built [this](https://github.com/sourcegraph/syntaxhighlight) awesome syntax-highlighting package.\n\n## Support\n\n### Backers\nSupport us with a monthly donation and help us continue our activities. [[Become a backer](https://opencollective.com/ccat#backer)]\n\n\u003ca href=\"https://opencollective.com/ccat/backer/0/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/0/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/1/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/1/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/2/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/2/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/3/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/3/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/4/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/4/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/5/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/5/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/6/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/6/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/7/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/7/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/8/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/8/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/9/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/9/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/10/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/10/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/11/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/11/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/12/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/12/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/13/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/13/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/14/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/14/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/15/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/15/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/16/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/16/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/17/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/17/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/18/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/18/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/19/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/19/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/20/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/20/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/21/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/21/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/22/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/22/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/23/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/23/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/24/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/24/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/25/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/25/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/26/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/26/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/27/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/27/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/28/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/28/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/backer/29/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/backer/29/avatar.svg\"\u003e\u003c/a\u003e\n\n\n### Sponsors\nBecome a sponsor and get your logo on our README on Github with a link to your site. [[Become a sponsor](https://opencollective.com/ccat#sponsor)]\n\n\u003ca href=\"https://opencollective.com/ccat/sponsor/0/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/0/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/1/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/1/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/2/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/2/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/3/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/3/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/4/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/4/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/5/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/5/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/6/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/6/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/7/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/7/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/8/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/8/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/9/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/9/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/10/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/10/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/11/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/11/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/12/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/12/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/13/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/13/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/14/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/14/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/15/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/15/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/16/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/16/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/17/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/17/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/18/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/18/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/19/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/19/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/20/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/20/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/21/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/21/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/22/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/22/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/23/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/23/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/24/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/24/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/25/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/25/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/26/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/26/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/27/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/27/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/28/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/28/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/ccat/sponsor/29/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/ccat/sponsor/29/avatar.svg\"\u003e\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fowenthereal%2Fccat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fowenthereal%2Fccat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fowenthereal%2Fccat/lists"}