{"id":20618176,"url":"https://github.com/oawu/golang-cli-xterm","last_synced_at":"2025-07-15T10:06:22.432Z","repository":{"id":59043512,"uuid":"527873045","full_name":"oawu/Golang-cli-xterm","owner":"oawu","description":"🌈 Golang 的 Cli 彩色文字工具","archived":false,"fork":false,"pushed_at":"2022-08-29T09:51:15.000Z","size":33,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-06T19:44:23.271Z","etag":null,"topics":["cli","golang","xterm"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oawu.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-08-23T07:06:48.000Z","updated_at":"2022-08-29T10:15:30.000Z","dependencies_parsed_at":"2022-09-11T04:41:50.765Z","dependency_job_id":null,"html_url":"https://github.com/oawu/Golang-cli-xterm","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/oawu/Golang-cli-xterm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oawu%2FGolang-cli-xterm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oawu%2FGolang-cli-xterm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oawu%2FGolang-cli-xterm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oawu%2FGolang-cli-xterm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oawu","download_url":"https://codeload.github.com/oawu/Golang-cli-xterm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oawu%2FGolang-cli-xterm/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265427361,"owners_count":23763294,"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":["cli","golang","xterm"],"created_at":"2024-11-16T12:07:28.477Z","updated_at":"2025-07-15T10:06:22.393Z","avatar_url":"https://github.com/oawu.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 歡迎使用 Golang 終端機色彩工具\n\n🌈 Golang Cli 下的色彩工具\n\n![OAWU's color Cli tool by golang](xterm.png)\n\n\n\n## 說明\n* 將終端機上輸出的文字給予色彩。\n\n\n## 使用\n``` go\npackage main\n\nimport (\n  \"fmt\"\n  \"github.com/oawu/Golang-cli-xterm\"\n)\n\nfunc main() {\n  fmt.Println()\n  fmt.Println(fmt.Sprintf(\"  印出紅色：%s\", xterm.Red(\"我是紅色\")))\n  fmt.Println(fmt.Sprintf(\"  背景綠色：%s\", xterm.BgGreen(\"我是綠色\")))\n  fmt.Println()\n  fmt.Println(\"  混用\")\n  fmt.Println()\n  fmt.Println(fmt.Sprintf(\"  紅色字綠色背景：%s\", xterm.Red(\"文字\").BgGreen()))\n  fmt.Println(fmt.Sprintf(\"  紅色「粗」字綠色背景：%s\", xterm.Red(\"文字\").BgGreen().Bold()))\n  fmt.Println(fmt.Sprintf(\"  黯淡紅色「粗」字綠色背景：%s\", xterm.Red(\"文字\").BgGreen().Bold().Dim()))\n  fmt.Println()\n}\n```\n![Golang-cli-xterm](demo.png)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foawu%2Fgolang-cli-xterm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foawu%2Fgolang-cli-xterm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foawu%2Fgolang-cli-xterm/lists"}