Skip to main content

A snappy CSV viewer TUI - peek at your data fast

Project description

csvpeek

A fast CSV viewer in your terminal - peek at your data instantly ⚡

License Python

Csvpeek is a snappy, memory-efficient CSV viewer built for speed. Powered by DuckDB for fast SQL-backed querying and Urwid for a lean terminal UI.

Features

  • Fast - DuckDB streaming with LIMIT/OFFSET keeps startup instant, even with huge files
  • Large File Support - Pagination handles millions of rows without breaking a sweat
  • Cell Selection - Select and copy ranges with keyboard shortcuts
  • Column Sorting - Sort by any column instantly
  • Keyboard-First - Every action is a keystroke away

Quick Start

Installation

uv tool install csvpeek

Or install from source:

git clone https://github.com/giantatwork/csvpeek.git
cd csvpeek
pip install -e .

Windows

Install the Microsoft Visual C++ Redistributable to ensure DuckDB works on Windows

Usage

csvpeek your_data.csv

Keyboard Shortcuts

Key Action
/ Open filter dialog
r Reset all filters
Ctrl+D Next page
Ctrl+U Previous page
s Sort current column
c Copy selection to clipboard
w Save selection to file
Shift+Arrow Select cells
Arrow Keys Navigate (clears selection)
q Quit

Usage Examples

Basic Viewing

Open any CSV file and start navigating immediately:

csvpeek data.csv

Filtering

  1. Press / to open the filter dialog
  2. Enter filter values for any columns
  3. Press Enter to apply
  4. Filter matches are highlighted in red

Filter modes:

  • Literal mode: Case-insensitive substring search (e.g., scranton matches "Scranton")
  • Regex mode: Start with / for regex patterns (e.g., /^J matches names starting with J)
    • /\d+ - Contains digits
    • /sales|eng - Contains "sales" OR "eng"
    • /^test$ - Exactly "test"
    • All regex patterns are case-insensitive

Sorting

  1. Navigate to any column
  2. Press s to sort by that column
  3. Press s again to toggle ascending/descending

Selection & Copy

  1. Position cursor on starting cell
  2. Hold Shift and use arrow keys to select a range
  3. Press c to copy selection as tab-separated values
  4. Paste anywhere with Ctrl+V

Requirements

  • Python 3.12+
  • DuckDB >= 1.1.0
  • Urwid >= 2.1.0
  • Pyperclip >= 1.9.0

License

MIT License - see LICENSE file for details

Acknowledgments

Built with amazing open-source tools:

  • DuckDB - Embedded analytics database
  • Urwid - Lightweight terminal UI toolkit

Contact

Found a bug? Have a feature request? Open an issue!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

csvpeek-0.10.6.tar.gz (34.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

csvpeek-0.10.6-py3-none-any.whl (19.3 kB view details)

Uploaded Python 3

File details

Details for the file csvpeek-0.10.6.tar.gz.

File metadata

  • Download URL: csvpeek-0.10.6.tar.gz
  • Upload date:
  • Size: 34.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for csvpeek-0.10.6.tar.gz
Algorithm Hash digest
SHA256 0d8f15be4e8cd9843d2f1429011450da926ac006d3965043ee542b95dbce93ee
MD5 1231f111b10e1a1c1ed425aacf7640b9
BLAKE2b-256 677d7a82e670835d6250a1f6c38dc06000b41b854baac44dfbdd1b95a1a14bf0

See more details on using hashes here.

File details

Details for the file csvpeek-0.10.6-py3-none-any.whl.

File metadata

  • Download URL: csvpeek-0.10.6-py3-none-any.whl
  • Upload date:
  • Size: 19.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for csvpeek-0.10.6-py3-none-any.whl
Algorithm Hash digest
SHA256 c38a0d83143a78cff122bb5714dc8af12e786dbe9900de1290df37654ee2bacc
MD5 9bafbf2c9e4a4e4e13a4e23560630397
BLAKE2b-256 c30cc3a805e3800e9bb76df84436036c57069e6d2bbca07c5bb68c9b9fe8463b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page