{"id":13365348,"url":"https://github.com/mattn/Go-isatty","last_synced_at":"2025-03-12T17:31:36.466Z","repository":{"id":15578904,"uuid":"18314451","full_name":"mattn/go-isatty","owner":"mattn","description":null,"archived":false,"fork":false,"pushed_at":"2024-08-03T07:07:53.000Z","size":63,"stargazers_count":831,"open_issues_count":14,"forks_count":108,"subscribers_count":12,"default_branch":"master","last_synced_at":"2024-10-29T14:04:50.327Z","etag":null,"topics":["cygwin","go","golang","isatty","msys2","website"],"latest_commit_sha":null,"homepage":"http://godoc.org/github.com/mattn/go-isatty","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/mattn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":"mattn","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2014-04-01T01:53:09.000Z","updated_at":"2024-10-27T20:52:34.000Z","dependencies_parsed_at":"2023-01-13T18:29:34.926Z","dependency_job_id":"e5df3856-af01-4f1e-bc33-49592abfccac","html_url":"https://github.com/mattn/go-isatty","commit_stats":{"total_commits":94,"total_committers":29,"mean_commits":"3.2413793103448274","dds":0.5,"last_synced_commit":"a7c02353c47bc4ec6b30dc9628154ae4fe760c11"},"previous_names":[],"tags_count":20,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Fgo-isatty","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Fgo-isatty/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Fgo-isatty/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattn%2Fgo-isatty/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mattn","download_url":"https://codeload.github.com/mattn/go-isatty/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243262059,"owners_count":20262946,"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":["cygwin","go","golang","isatty","msys2","website"],"created_at":"2024-07-30T00:01:05.178Z","updated_at":"2025-03-12T17:31:36.432Z","avatar_url":"https://github.com/mattn.png","language":"Go","readme":"# go-isatty\n\n[![Godoc Reference](https://godoc.org/github.com/mattn/go-isatty?status.svg)](http://godoc.org/github.com/mattn/go-isatty)\n[![Codecov](https://codecov.io/gh/mattn/go-isatty/branch/master/graph/badge.svg)](https://codecov.io/gh/mattn/go-isatty)\n[![Coverage Status](https://coveralls.io/repos/github/mattn/go-isatty/badge.svg?branch=master)](https://coveralls.io/github/mattn/go-isatty?branch=master)\n[![Go Report Card](https://goreportcard.com/badge/mattn/go-isatty)](https://goreportcard.com/report/mattn/go-isatty)\n\nisatty for golang\n\n## Usage\n\n```go\npackage main\n\nimport (\n\t\"fmt\"\n\t\"github.com/mattn/go-isatty\"\n\t\"os\"\n)\n\nfunc main() {\n\tif isatty.IsTerminal(os.Stdout.Fd()) {\n\t\tfmt.Println(\"Is Terminal\")\n\t} else if isatty.IsCygwinTerminal(os.Stdout.Fd()) {\n\t\tfmt.Println(\"Is Cygwin/MSYS2 Terminal\")\n\t} else {\n\t\tfmt.Println(\"Is Not Terminal\")\n\t}\n}\n```\n\n## Installation\n\n```\n$ go get github.com/mattn/go-isatty\n```\n\n## License\n\nMIT\n\n## Author\n\nYasuhiro Matsumoto (a.k.a mattn)\n\n## Thanks\n\n* k-takata: base idea for IsCygwinTerminal\n\n    https://github.com/k-takata/go-iscygpty\n","funding_links":["https://github.com/sponsors/mattn"],"categories":["命令行"],"sub_categories":["高级控制台界面","高級控制台界面"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmattn%2FGo-isatty","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmattn%2FGo-isatty","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmattn%2FGo-isatty/lists"}