{"id":13543070,"url":"https://github.com/jesseduffield/gocui","last_synced_at":"2025-04-02T12:31:09.960Z","repository":{"id":34981581,"uuid":"136146190","full_name":"jesseduffield/gocui","owner":"jesseduffield","description":"Minimalist Go package aimed at creating Console User Interfaces.","archived":false,"fork":true,"pushed_at":"2025-02-07T13:17:47.000Z","size":751,"stargazers_count":236,"open_issues_count":1,"forks_count":32,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-02-07T14:25:25.849Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"jroimartin/gocui","license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jesseduffield.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGES_tcell.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2018-06-05T08:34:39.000Z","updated_at":"2025-02-07T13:17:46.000Z","dependencies_parsed_at":"2023-01-16T23:01:05.163Z","dependency_job_id":"2478c4fd-c111-4548-bb3f-2674ece551a3","html_url":"https://github.com/jesseduffield/gocui","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesseduffield%2Fgocui","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesseduffield%2Fgocui/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesseduffield%2Fgocui/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesseduffield%2Fgocui/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jesseduffield","download_url":"https://codeload.github.com/jesseduffield/gocui/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246815442,"owners_count":20838439,"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-08-01T11:00:22.480Z","updated_at":"2025-04-02T12:31:04.946Z","avatar_url":"https://github.com/jesseduffield.png","language":"Go","readme":"# GOCUI - Go Console User Interface\n[![CircleCI](https://circleci.com/gh/awesome-gocui/gocui/tree/master.svg?style=svg)](https://circleci.com/gh/awesome-gocui/gocui/tree/master)\n[![CodeCov](https://codecov.io/gh/awesome-gocui/gocui/branch/master/graph/badge.svg)](https://codecov.io/gh/awesome-gocui/gocui)\n[![Go Report Card](https://goreportcard.com/badge/github.com/awesome-gocui/gocui)](https://goreportcard.com/report/github.com/awesome-gocui/gocui)\n[![GolangCI](https://golangci.com/badges/github.com/awesome-gocui/gocui.svg)](https://golangci.com/badges/github.com/awesome-gocui/gocui.svg)\n[![GoDoc](https://godoc.org/github.com/awesome-gocui/gocui?status.svg)](https://godoc.org/github.com/awesome-gocui/gocui)\n![GitHub tag (latest SemVer)](https://img.shields.io/github/tag/awesome-gocui/gocui.svg)\n\nMinimalist Go package aimed at creating Console User Interfaces.\nA community fork based on the amazing work of [jroimartin](https://github.com/jroimartin/gocui)\n\n## Features\n\n* Minimalist API.\n* Views (the \"windows\" in the GUI) implement the interface io.ReadWriter.\n* Support for overlapping views.\n* The GUI can be modified at runtime (concurrent-safe).\n* Global and view-level keybindings.\n* Mouse support.\n* Colored text.\n* Customizable editing mode.\n* Easy to build reusable widgets, complex layouts...\n\n## About fork\n\nThis fork has many improvements over the original work from [jroimartin](https://github.com/jroimartin/gocui).\n\n* Written ontop of TCell\n* Better wide character support\n* Support for 1 Line height views\n* Better support for running in docker container\n* Customize frame colors\n* Improved code comments and quality\n* Many small improvements\n* Change Visibility of views\n\nFor information about this org see: [awesome-gocui/about](https://github.com/awesome-gocui/about).\n\n## Installation\n\nExecute:\n\n```\n$ go get github.com/awesome-gocui/gocui\n```\n\n## Documentation\n\nExecute:\n\n```\n$ go doc github.com/awesome-gocui/gocui\n```\n\nOr visit [godoc.org](https://godoc.org/github.com/awesome-gocui/gocui) to read it\nonline.\n\n## Example\nSee the [_example](./_example/) folder for more examples\n\n```go\npackage main\n\nimport (\n\t\"fmt\"\n\t\"log\"\n\n\t\"github.com/awesome-gocui/gocui\"\n)\n\nfunc main() {\n\tg, err := gocui.NewGui(gocui.OutputNormal, true)\n\tif err != nil {\n\t\tlog.Panicln(err)\n\t}\n\tdefer g.Close()\n\n\tg.SetManagerFunc(layout)\n\n\tif err := g.SetKeybinding(\"\", gocui.KeyCtrlC, gocui.ModNone, quit); err != nil {\n\t\tlog.Panicln(err)\n\t}\n\n\tif err := g.MainLoop(); err != nil \u0026\u0026 !gocui.IsQuit(err) {\n\t\tlog.Panicln(err)\n\t}\n}\n\nfunc layout(g *gocui.Gui) error {\n\tmaxX, maxY := g.Size()\n\tif v, err := g.SetView(\"hello\", maxX/2-7, maxY/2, maxX/2+7, maxY/2+2, 0); err != nil {\n\t\tif !gocui.IsUnknownView(err) {\n\t\t\treturn err\n\t\t}\n\n\t\tif _, err := g.SetCurrentView(\"hello\"); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tfmt.Fprintln(v, \"Hello world!\")\n\t}\n\n\treturn nil\n}\n\nfunc quit(g *gocui.Gui, v *gocui.View) error {\n\treturn gocui.ErrQuit\n}\n```\n\n## Screenshots\n\n![r2cui](https://cloud.githubusercontent.com/assets/1223476/19418932/63645052-93ce-11e6-867c-da5e97e37237.png)\n\n![_examples/demo.go](https://cloud.githubusercontent.com/assets/1223476/5992750/720b84f0-aa36-11e4-88ec-296fa3247b52.png)\n\n![_examples/dynamic.go](https://cloud.githubusercontent.com/assets/1223476/5992751/76ad5cc2-aa36-11e4-8204-6a90269db827.png)\n\n## Projects using gocui\n\n* [komanda-cli](https://github.com/mephux/komanda-cli): IRC Client For Developers.\n* [vuls](https://github.com/future-architect/vuls): Agentless vulnerability scanner for Linux/FreeBSD.\n* [wuzz](https://github.com/asciimoo/wuzz): Interactive cli tool for HTTP inspection.\n* [httplab](https://github.com/gchaincl/httplab): Interactive web server.\n* [domainr](https://github.com/MichaelThessel/domainr): Tool that checks the availability of domains based on keywords.\n* [gotime](https://github.com/nanohard/gotime): Time tracker for projects and tasks.\n* [claws](https://github.com/thehowl/claws): Interactive command line client for testing websockets.\n* [terminews](http://github.com/antavelos/terminews): Terminal based RSS reader.\n* [diagram](https://github.com/esimov/diagram): Tool to convert ascii arts into hand drawn diagrams.\n* [pody](https://github.com/JulienBreux/pody): CLI app to manage Pods in a Kubernetes cluster.\n* [kubexp](https://github.com/alitari/kubexp): Kubernetes client.\n* [kcli](https://github.com/cswank/kcli): Tool for inspecting kafka topics/partitions/messages.\n* [fac](https://github.com/mkchoi212/fac): git merge conflict resolver\n* [jsonui](https://github.com/gulyasm/jsonui): Interactive JSON explorer for your terminal.\n* [cointop](https://github.com/miguelmota/cointop): Interactive terminal based UI application for tracking cryptocurrencies.\n* [lazygit](https://github.com/jesseduffield/lazygit): simple terminal UI for git commands.\n* [lazydocker](https://github.com/jesseduffield/lazydocker): The lazier way to manage everything docker.\n\nNote: if your project is not listed here, let us know! :)\n","funding_links":[],"categories":["Go"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjesseduffield%2Fgocui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjesseduffield%2Fgocui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjesseduffield%2Fgocui/lists"}