explaingit

charmbracelet/gum

Analysis updated 2026-06-21

23,562GoAudience · developerComplexity · 2/5Setup · easy

TLDR

A CLI tool that adds polished interactive elements, text prompts, choice menus, confirmation dialogs, file pickers, and loading spinners, to any shell script using simple one-line commands, no Go knowledge required.

Mindmap

mindmap
  root((repo))
    What it does
      Interactive shell elements
      Drop into any script
      No Go required
    Components
      Text input prompts
      Choice menus
      Confirmation dialogs
      File pickers
      Loading spinners
    Customization
      Colors and borders
      Env var flags
    Audience
      Shell scripters
      Developers
      Sysadmins
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Add a choice menu to a Bash script so users pick from a list instead of typing raw input.

USE CASE 2

Build an interactive Git commit workflow script that prompts for commit type, scope, and message.

USE CASE 3

Show a loading spinner in a shell script while a slow command runs so users know it hasn't frozen.

USE CASE 4

Create a file picker inside a shell script so users select which files to process without hard-coding paths.

What is it built with?

Go

How does it compare?

charmbracelet/gumquii/learn-go-with-teststerrastruct/d2
Stars23,56223,62723,630
LanguageGoGoGo
Setup difficultyeasyeasyeasy
Complexity2/52/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min

In plain English

Gum is a command-line tool written in Go that lets you add interactive, visually polished elements to plain shell scripts without needing to know Go. Think of a normal shell script as a set of instructions a computer follows, the problem is those scripts are usually just plain text with no way to ask the user for input in a friendly way, or show progress nicely. Gum solves this by giving you simple commands you can drop into any Bash or shell script to add things like text prompts, dropdown choice menus, confirmation dialogs, file pickers, loading spinners, and scrollable text viewers. The way it works is simple: each interactive element is its own subcommand (for example, "gum input" to collect typed text, "gum choose" to present a menu, "gum confirm" to ask yes or no). These commands print their result to standard output, so you can capture the user's answer in a variable and use it later in your script. You control the look and feel through command flags or environment variables, changing colors, borders, widths, and prompts without writing any interface code yourself. You would use Gum when you want to build a script that guides someone through a multi-step task, like automating a Git commit workflow, selecting files to process, or confirming a destructive action, and you want the result to feel polished rather than raw. It runs in the terminal, so it suits developers, system administrators, and power users who live in the command line. It is written in Go and builds on the Bubbles and Lip Gloss libraries from the same team.

Copy-paste prompts

Prompt 1
I want to add a multi-step wizard to my Bash script using gum. Show me how to collect a name with gum input, pick an option with gum choose, and confirm with gum confirm.
Prompt 2
Write a shell script that uses gum to build an interactive Git commit helper, ask for commit type, scope, and message, then run git commit with the result.
Prompt 3
Show me how to style gum prompts with custom colors and borders using gum's environment variable flags, without writing any Go code.
Prompt 4
I want to show a spinner in my Bash script while a curl request runs. How do I wrap the curl command with gum spin?

Frequently asked questions

What is gum?

A CLI tool that adds polished interactive elements, text prompts, choice menus, confirmation dialogs, file pickers, and loading spinners, to any shell script using simple one-line commands, no Go knowledge required.

What language is gum written in?

Mainly Go. The stack also includes Go.

How hard is gum to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is gum for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub charmbracelet on gitmyhub

Verify against the repo before relying on details.