Skip to content

A beautiful terminal-based spreadsheet editor with Vim-style keybindings, AI formula generation, and rich visualization.

License

Notifications You must be signed in to change notification settings

SreeAditya-Dev/Cello-TUI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

16 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

๐Ÿ“Š Cello - Terminal Spreadsheet Editor

A beautiful, fast, and feature-rich terminal-based Excel and CSV editor with vim-style keybindings and formula support.

Go Version License Version

Cello Demo

โœจ Features

โœจ AI Formula Generation (NEW!)

Don't know the formula syntax? Just describe what you want in plain English:

  • Press Ctrl+K to open AI Formula Generator
  • Type: "Sum of column A" โ†’ Gets =SUM(A:A)
  • Type: "Average of B1 to B10" โ†’ Gets =AVERAGE(B1:B10)
  • Type: "Extract domain from email in A1" โ†’ Gets the right formula!
  • Press Tab to insert the generated formula

Multiple AI Providers Supported:

  • Gemini (Google)
  • OpenAI (GPT-4, GPT-3.5)
  • Claude (Anthropic)
  • Mistral
  • OpenRouter (access any model)

Press Ctrl+, to open configuration and set your preferred provider and API key.

Configuration: Run cello config to set up your AI provider and API key.

๐Ÿงน Smart Data Cleaning (NEW!)

Messy data? Cello can help you clean it up instantly:

  • Press Ctrl+B to open the Data Cleaning tool
  • Trim Whitespace: Remove leading/trailing spaces
  • Remove Duplicates: Eliminate duplicate rows
  • Fix Numbers: Convert text-formatted numbers to actual numbers
  • Preview Changes: See exactly what will happen before you apply

๐Ÿ“ Powerful Formula Engine

Arithmetic: =A1+B1, =C1*2, =D1/E1-F1

15+ Built-in Functions:

  • SUM(A1:A10) - Sum range
  • AVERAGE(B1:B20) / AVG(...) - Average values
  • COUNT(C1:C50) - Count numbers
  • MAX(D1:D100) / MIN(...) - Find max/min
  • IF(A1>100, "High", "Low") - Conditional logic
  • CONCATENATE(A1, " ", B1) / CONCAT(...) - Join text
  • UPPER(A1) / LOWER(A1) - Change case
  • LEN(A1) - Text length
  • ROUND(A1, 2) - Round numbers
  • ABS(A1) - Absolute value
  • SQRT(A1) - Square root
  • POWER(2, 8) / POW(...) - Exponentiation

Auto-recalculation when cells change

โœ๏ธ Full Editing Capabilities

  • Edit cells with formulas and values
  • Insert/delete rows and columns
  • Copy/paste single cells or ranges
  • Fill down/right for quick data entry
  • Apply formulas to entire ranges with automatic reference adjustment
  • Auto-save with modification tracking
  • Undo-friendly workflow with clear status messages

๐Ÿ“Š Live Data Visualization

  • Bar charts - Compare values visually
  • Line charts - Show trends over time
  • Sparklines - Compact inline charts
  • Pie charts - Display proportions

How to use:

  1. Press V to start range selection
  2. Move cursor and press V again
  3. Press v to open visualization
  4. Press 1-4 to switch chart types

๐Ÿ” Powerful Navigation

  • Vim-style keybindings (hjkl) and arrow keys
  • Jump to cell (Ctrl+G) - supports A100, 500, or 10,5 formats
  • Search (/) across cells and formulas
  • Navigate results (n/N)
  • Page Up/Down, Home/End
  • Multi-sheet support with Tab navigation

๐Ÿ“‹ Data Operations

  • Copy cell (c) or entire row (C)
  • Paste (p) with multi-cell support
  • Export to CSV or JSON
  • Save (Ctrl+S) with format preservation
  • Save As (Ctrl+Shift+S) to new file
  • Toggle formula display (f)
  • View cell details (Enter)
  • Column Resizing (< / >)
  • Data Cleaning (Ctrl+B)

๏ฟฝ File Support

  • Excel files (.xlsx, .xlsm, .xls) with formula preservation
  • CSV files with formula support (saved as text)
  • Multiple sheets with easy navigation
  • Large file optimization with lazy loading
  • Safe saving with backup on errors

๐ŸŽจ Ten Beautiful Themes

Dark Themes:

  • Catppuccin Mocha - Soft pastels, perfect for all-day use
  • Nord - Cool Arctic blues, minimal and focused
  • Rosรฉ Pine - Elegant rose tones, sophisticated
  • Tokyo Night - Vibrant cyberpunk aesthetic
  • Gruvbox - Warm retro colors, comfortable
  • Dracula - Classic high contrast theme

Light Themes:

  • Catppuccin Latte - Gentle pastel light theme
  • Solarized Light - Balanced contrast
  • GitHub Light - Clean and minimal
  • One Light - Soft Atom-inspired colors

๐Ÿš€ Installation

Using Homebrew (macOS/Linux)

brew install SreeAditya-Dev/tap/cello

Using go install

go install github.com/SreeAditya-Dev/cello-tui@latest

Download Binary

Download pre-built binaries from the releases page.

Available for:

  • macOS (Intel & Apple Silicon)
  • Linux (x64 & ARM64)
  • Windows (x64)

Build from Source

# Clone the repository
git clone https://github.com/SreeAditya-Dev/cello-tui.git
cd cello-tui

# Install dependencies
go mod download

# Build
go build -o cello .

# Optional: Install globally
sudo mv cello /usr/local/bin/

๐Ÿ“– Usage

# View a file (read-only until you press 'i')
cello data.xlsx

# Start with a specific theme
cello report.csv --theme nord

# Create new file (will be created on first save)
cello newfile.xlsx

โŒจ๏ธ Keyboard Shortcuts

Navigation

  • โ†‘โ†“โ†โ†’ or hjkl - Navigate cells
  • Page Up/Down or Ctrl+U/D - Scroll by page
  • Home/End or 0/$ - First/last column
  • g/G - First/last column
  • Tab/Shift+Tab - Next/previous sheet
  • Ctrl+G - Jump to specific cell

Editing

  • i - Enter edit mode
  • Enter - Commit changes (in edit) / View details (in normal)
  • Tab - Save and move right (in edit mode)
  • Shift+Tab - Save and move left (in edit mode)
  • Esc - Cancel editing
  • x - Delete cell content
  • dd - Delete current row
  • dc - Delete current column

Cell Operations

  • c - Copy cell
  • C - Copy entire row
  • p - Paste
  • o - Insert row below
  • O - Insert column right
  • Ctrl+J - Fill down (requires selection)
  • Ctrl+L - Fill right (requires selection)
  • Ctrl+A - Apply formula to range (requires selection)
  • < / > - Decrease / Increase column width
  • Ctrl+B - Clean data (trim whitespace)

File Operations

  • Ctrl+S - Save file
  • Ctrl+Shift+S - Save as
  • e - Export to CSV/JSON
  • q - Quit (press twice if unsaved changes)

Search & Navigation

  • / - Search
  • n/N - Next/previous search result
  • Esc - Clear search

Visualization & Display

  • V - Start/finish range selection
  • v - Open visualization (after selection)
  • 1-4 - Switch chart types (in viz mode)
  • f - Toggle formula display
  • t - Change theme
  • ? - Toggle help
  • Ctrl+K - AI Formula Generator
  • Ctrl+, - Configure AI Providers

๐Ÿ’ก Quick Start Guide

Viewing a File

cello mydata.xlsx
# Navigate with arrow keys or hjkl
# Press 'f' to toggle formula view
# Press 't' to change theme

Editing Data

# 1. Open file
cello mydata.xlsx

# 2. Navigate to a cell
# 3. Press 'i' to edit
# 4. Type value or formula: =SUM(A1:A10)
# 5. Press Enter to save
# 6. Press Ctrl+S to save file

Working with Formulas

# Create a formula
Press 'i' on cell C1
Type: =A1+B1
Press Enter

# Apply to entire column
Press 'V' to start selection at C1
Move to C10 and press 'V'
Move back to C1
Press Ctrl+A to apply formula
# Result: C1=A1+B1, C2=A2+B2, C3=A3+B3, etc.

Bulk Data Entry

Press 'i' to start editing
Type value and press Tab
Continue typing in next cell
Press Tab to keep moving right
Press Ctrl+S when done

๐Ÿ—๏ธ Project Structure

cello-tui/
โ”œโ”€โ”€ main.go                    # Application entry point
โ”œโ”€โ”€ internal/
โ”‚   โ”œโ”€โ”€ app/
โ”‚   โ”‚   โ”œโ”€โ”€ model.go          # State management
โ”‚   โ”‚   โ”œโ”€โ”€ update.go         # Event handling
โ”‚   โ”‚   โ”œโ”€โ”€ view.go           # Rendering logic
โ”‚   โ”‚   โ”œโ”€โ”€ keys.go           # Keybindings
โ”‚   โ”‚   โ”œโ”€โ”€ edit.go           # Edit operations
โ”‚   โ”‚   โ””โ”€โ”€ formulas.go       # Formula evaluation engine
โ”‚   โ”œโ”€โ”€ loader/
โ”‚   โ”‚   โ”œโ”€โ”€ loader.go         # File loading
โ”‚   โ”‚   โ””โ”€โ”€ save.go           # File saving
โ”‚   โ”œโ”€โ”€ theme/
โ”‚   โ”‚   โ””โ”€โ”€ theme.go          # Theme definitions
โ”‚   โ””โ”€โ”€ ui/
โ”‚       โ””โ”€โ”€ ui.go             # UI utilities
โ””โ”€โ”€ pkg/
    โ””โ”€โ”€ models/
        โ””โ”€โ”€ models.go         # Data models

๐Ÿค Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Development Setup

git clone https://github.com/SreeAditya-Dev/cello-tui.git
cd cello-tui

# Install dependencies
make deps

# Run tests
make test

# Build
make build

# Run with sample data
make run

Code Style

  • Run make fmt before committing
  • Follow Effective Go guidelines
  • Add tests for new features
  • Update documentation

๐Ÿ“Š Examples

Sales Report with Formulas

     A        B        C          D
1  Item     Price    Qty      Total
2  Apples   1.50     10      =B2*C2
3  Oranges  2.00     5       =B3*C3
4  Total    -        -       =SUM(D2:D3)

Select D2:D4, cursor on D2, press Ctrl+A to apply formula pattern.

Conditional Formatting (Formula-based)

     A           B
1  Score    Grade
2  85       =IF(A2>=90,"A",IF(A2>=80,"B","C"))

Apply to B2:B20 with Ctrl+A for instant grading.

Data Summary

     A              B
1  Sales         1000
2  Costs          600
3  Profit      =A1-A2
4  Margin      =ROUND(A3/A1*100,2)

๐Ÿ”ง Advanced Features

Formula Auto-adjustment

When you apply a formula to a range, cell references automatically adjust:

Source: A1 contains =B1+C1

Apply to A1:A5:
  A1: =B1+C1
  A2: =B2+C2
  A3: =B3+C3
  A4: =B4+C4
  A5: =B5+C5

Multi-cell Paste

Copy ranges from other apps and paste into Cello:

  • Tab-separated values paste as multiple columns
  • Newline-separated values paste as multiple rows
  • Formulas (starting with =) are preserved

Keyboard-driven Workflow

i          Enter edit mode
Type data
Tab        Save and move to next cell
Tab        Continue entering data
Tab        Keep going...
Ctrl+S     Save entire file

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

๐Ÿ”’ Security

If you discover a security vulnerability, please create a private security advisory on GitHub or email the maintainers.

๐Ÿ“ฎ Contact

โญ Star History

If you find Cello useful, please consider giving it a star on GitHub!


Made with โค๏ธ for terminal enthusiasts and spreadsheet power users everywhere.

About

A beautiful terminal-based spreadsheet editor with Vim-style keybindings, AI formula generation, and rich visualization.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks