tcell VS termenv

Compare tcell vs termenv and see what are their differences.

tcell

Tcell is an alternate terminal package, similar in some ways to termbox, but better in others. (by gdamore)

termenv

Advanced ANSI style & color support for your terminal applications (by muesli)
Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
tcell termenv
18 6
4,368 1,632
- -
8.8 6.0
10 days ago 2 months ago
Go Go
Apache License 2.0 MIT License
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

tcell

Posts with mentions or reviews of tcell. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-06-02.
  • go playground code doesn't work locally?
    2 projects | /r/golang | 2 Jun 2023
    https://github.com/gdamore/tcell s, err := tcell.NewScreen() // Clear screen s.Clear()
  • Help to find a terminal library
    3 projects | /r/golang | 12 Mar 2023
    I have used https://github.com/gdamore/tcell/ for github.com/raff/gio-games/arrows (look at game_term.go that is the terminal version, alternative to the gio/graphical version)
  • Problem Installing Go Modules
    1 project | /r/golang | 5 Feb 2023
    Hi im using linux (distro: Fedora 37) and I dont i have problems with installing go modules. When i run the commands in terminal (bash) "go install github.com/gdamore/tcell/v2" it gives me this error: "go: 'go install' requires a version when current directory is not in a module Try 'go install github.com/gdamore/tcell/v2@latest' to install the latest version" So when I run the command: "go install github.com/gdamore/tcell/vs@latest" I get this error: "package github.com/gdamore/tcell/v2 is not a main package". Please someone help.
  • How to Create Console Screen Buffer in go?
    4 projects | /r/golang | 20 Jan 2023
    Hi guys, I have fixed the problem. The problem was as stated: remove terminal behavior like when a key is pressed and held it does not work as needed. For example if I want to move character when user press key the player (character) will move one step then stops then move fast like text curser. The solution is not by using [Console Screen Buffer] the Tcell is enough, But the problem is caused by the way the input is read from the user as u/pekim says in comments it is a "Typical behaviour in most environments (not just Windows)". So to fix this you need to use windows API (w32) and read key using GetAsyncKeyState() that will fix the problem.
  • Need a TUI with multiline text input or good interactive CLI-interface style support
    6 projects | /r/golang | 21 Jul 2022
    There's quite a variety of tui libraries in Go with all kinds of different tradeoffs. Likely you won't find one that does just exactly what you want (paren matching support seems particularly unlikely out of the box, dunno if you'll find something you can plug in). tview and the underlying, lower-level tcell may be useful. I see termbox mentioned a lot here though that looks more like a toolbox for building such things than a solution itself.
  • Which Go frameworks are recommended to assist with the creation of console based UI and GUI?
    5 projects | /r/golang | 21 May 2022
    There's also tcell
  • TUIs
    33 projects | news.ycombinator.com | 16 Mar 2022
    How about some libraries that help with building TUIs?

    I'll start with https://github.com/gdamore/tcell

  • Monotty Desktopio - Text-based desktop environment inside your terminal
    12 projects | /r/commandline | 7 Feb 2022
    (notcurses is the first in C, and currently best globally. The first in Rust might be tui-rs. The first in Go might be tcell.)
  • tcell VS FINAL CUT - a user suggested alternative
    2 projects | 1 Jan 2022
  • Snake game implementation.
    2 projects | /r/golang | 20 Oct 2021
    a Snake Game implication in Go using 2d array. https://github.com/twiny/snaky it runs on terminal window using github.com/gdamore/tcell/v2/termbox to render Snake movement.

termenv

Posts with mentions or reviews of termenv. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-06-02.
  • go playground code doesn't work locally?
    2 projects | /r/golang | 2 Jun 2023
    For example: https://github.com/muesli/termenv // Clear the visible portion of the terminal output := termenv.NewOutput(os.Stdout) output.ClearScreen()
  • tint: šŸŒˆ slog.Handler that writes tinted logs
    3 projects | /r/golang | 27 Mar 2023
    Why not let termenv do the hard part of making this portable across terminals? It also supports lesser-known conventions like NO_COLOR.
  • Tran - šŸ–„ Securely transfer and send anything between computers with TUI.
    9 projects | dev.to | 10 Feb 2022
    Termenv
  • Show HN: Lip Gloss a CSS-like layout library for the terminal for Go
    3 projects | news.ycombinator.com | 3 Apr 2021
  • Tz: A Time Zone Helper
    5 projects | news.ycombinator.com | 21 Mar 2021
    Look, you and I may have sane ANSI 16 colours, but itā€™ll be a very significant fraction of people that donā€™t (and almost no one will customise the next 240 colours). Remember things like that thereā€™s a fairly high chance that blue is almost invisible against black, and even bright blueā€™s contrast is commonly much too lowā€”to say nothing of the limited palette range.

    But what this program is doing is using termenvā€™s HasDarkBackground function to decide whether the terminal is light or dark, and is then specifying RGB colours. Iā€™d guess that itā€™ll try to guess whether to use 16 colours, 256 colours or 24-bit colour, but I donā€™t know. But the way it figures out the terminalā€™s background colourā€¦ ugh. Some terminals will support it, but for many itā€™ll fail and just assume black. Looks like on unix you could set an environment variable COLORFGBG to override this, https://github.com/muesli/termenv/blob/6bb55115565c27f4cc681..., but if youā€™re on Windows, tough luck, apparently youā€™re not allowed to have run `color f0` (Command Prompt) or similar: https://github.com/muesli/termenv/blob/537e36cb0472a69a3c828....

    The simple fact of the matter is that there are no particularly good solutions for handling colour in terminals if you want the colours to cohere and map to real-world colour understanding, which is what something like this would prefer to be able to do.

What are some alternatives?

When comparing tcell and termenv you can also consider the following projects:

bubbletea - A powerful little TUI framework šŸ—

pterm - āœØ #PTerm is a modern Go module to easily beautify console output. Featuring charts, progressbars, tables, trees, text input, select menus and much more šŸš€ It's completely configurable and 100% cross-platform compatible.

termbox-go - Pure Go termbox implementation

notcurses - blingful character graphics/TUI library. definitely not curses.

termdash - Terminal based dashboard.

termui - Golang terminal dashboard

go-isatty

gocui - Minimalist Go package aimed at creating Console User Interfaces.

mpb - multi progress bar for Go cli applications

Rich Interactive Widgets for Terminal UIs - Terminal UI library with rich, interactive widgets ā€”Ā written in Golang

go-prompt - Building powerful interactive prompts in Go, inspired by python-prompt-toolkit.