Skip to content

jakmaz/arcade

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Arcade

Arcade is a collection of classic games for your terminal, written in Go using Bubble Tea and Cobra CLI. Play Snake, Tetris, Chess, and Tic-Tac-Toe directly from the command line - perfect for quick breaks between coding sessions.

Features

  • Terminal Native: Runs entirely in your terminal with rich TUI
  • Multiple Games: Snake, Tetris, Chess, and Tic-Tac-Toe
  • Theming System: 6 built-in themes with support for system theme detection and custom themes
  • Extensible: Easy to add new games with consistent UI patterns

Installation

go install github.com/jakmaz/arcade@latest

Usage

Interactive Menu

Launch the interactive game menu:

arcade

Other Commands

arcade list                # List all available games
arcade play [game]         # Start a game directly
arcade --help              # View all available commands and options
arcade --version           # Show version information

Games

Game Description Preview
Snake Classic snake game - eat food, grow longer, avoid walls Snake
Tetris Block puzzle game with falling pieces and line clearing Tetris
Chess Strategic board game with full piece movement Chess
Tic-Tac-Toe Classic X's and O's game Tic-Tac-Toe

Themes

Arcade supports multiple built-in themes with custom theme support:

  • Dracula - Dark theme with purple accents
  • GitHub - GitHub's dark color scheme
  • Gruvbox Dark - Warm, retro color scheme
  • Nord - Arctic, north-bluish theme
  • Tokyo Night - Dark theme with neon highlights

Custom Themes

Create custom themes by adding YAML files to ~/.config/arcade:

name: mytheme
palette:
  bg: "#1a1a1a"
  fg: "#ffffff"
  # ... more colors
ui:
  primary: fg
  accent: purple
  # ... UI mappings

You can find the structure of the theme file in internal/theme/themes/dracula.yaml. If you are happy with your theme, please consider contributing it back to the project!

Contributing

Arcade welcomes contributions! Whether you want to add new games, new themes, fix bugs, or improve the UI, your help is highly appreciated. The ultimate goal is to make arcade an amazing community-driven game collection for your terminal.

Adding a New Game

  1. Create a new package in internal/games/yourgame/
  2. Implement the Bubble Tea model interface:
    type Model struct { /* your game state */ }
    func (m Model) Init() tea.Cmd { /* initialization */ }
    func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) { /* handle input */ }
    func (m Model) View() tea.View { /* render UI */ }
  3. Register your game in internal/core/games.go
  4. Follow existing UI patterns from other games
  5. Use the shared styles from internal/ui/styles/

Acknowledgments

License

This project is licensed under the MIT License.

About

Classic games for your terminal, written in Go

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published