npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

dataset-cli

v1.0.14

Published

Dataset processing CLI tool

Downloads

1,617

Readme

Dataset CLI

A powerful CLI tool for processing and querying datasets with support for SQLite, PostgreSQL, and TursoDB (cloud SQLite).

License Go Platform

Features

  • Multiple Databases - Works with SQLite (default), PostgreSQL, and TursoDB cloud
  • Smart Data Import - Import CSV/JSON files with automatic type detection
  • Beautiful CLI - Color-coded output, progress bars, interactive prompts
  • No SQL Required - Interactive query builder for non-technical users
  • Streaming Import - Handle large files efficiently with low memory usage
  • Data Validation - Pre-flight checks before import
  • Multiple Output Formats - Table, JSON, CSV, Markdown, Pretty print

Installation

npm (Recommended)

npm install -g dataset-cli

Works on Windows, macOS, and Linux. Binary is downloaded automatically on first run.

Download Binary

Download the latest release for your platform from GitHub Releases.

Docker

docker pull darshan192004/dataset-cli
docker run --rm darshan192004/dataset-cli --help

Build from Source

git clone https://github.com/darshan192004/cli-project.git
cd cli-project
go build -o dataset-cli .

Quick Start

# Start interactive mode
dataset-cli

# Import a CSV file
dataset-cli migrate data.csv

# Filter data with SQL-like syntax
dataset-cli filter users --where "age > 25"

# Export to JSON
dataset-cli export users --output data.json

# Check system health
dataset-cli doctor

Commands

migrate - Import Data

# Basic import (creates table from filename)
dataset-cli migrate data.csv

# Specify table name
dataset-cli migrate data.csv --table-name users

# With options
dataset-cli migrate data.csv \
  --table-name users \
  --drop \           # Drop existing table first
  --skip-errors \    # Continue on errors
  --progress         # Show progress bar

# Use PostgreSQL
dataset-cli migrate data.csv --postgres

# Use TursoDB Cloud
dataset-cli migrate data.csv --cloud

filter - Query Data

# Interactive mode
dataset-cli filter

# SQL-like query
dataset-cli filter users --where "age > 25 AND city = 'NYC'" --limit 10

# Simple query
dataset-cli filter users

transform - Select Columns

# Select specific columns
dataset-cli transform users --columns name,email,age

# With filter
dataset-cli transform users \
  --columns name,email \
  --where "city = 'New York'"

export - Export Data

# JSON (default)
dataset-cli export users --output data.json

# CSV
dataset-cli export users --output data.csv --format csv

# Markdown (great for docs)
dataset-cli export users --output data.md --format md

# Pretty print to terminal
dataset-cli export users --format pretty

schema - View Table Schema

dataset-cli schema users

stats - Table Statistics

# Basic stats
dataset-cli stats users

# Include NULL counts
dataset-cli stats users --show-nulls

aggregate - Aggregate Functions

# Count records
dataset-cli aggregate users --operation count

# Sum a column
dataset-cli aggregate orders --operation sum --column amount

# Average, min, max
dataset-cli aggregate users --operation avg --column age

backup & restore - Data Backup

# Backup a table
dataset-cli backup users --output backup.json

# Restore from backup
dataset-cli restore users --input backup.json

doctor - System Diagnostics

dataset-cli doctor

Global Flags

dataset-cli [command] [flags]

Flags:
  -v, --verbose           Enable verbose output
      --dry-run           Show what would be done without executing
      --no-color          Disable color output
      --config string     Config file path (default ~/.dataset-cli.yaml)
      --postgres          Use PostgreSQL instead of SQLite
      --cloud             Use TursoDB cloud (requires LIBSQL_URL env var)
      --host string       Database host (overrides config)
      --port int          Database port (overrides config)
      --user string       Database user (overrides config)
      --password string   Database password (overrides config)
      --dbname string     Database name (overrides config)

Configuration

Create ~/.dataset-cli.yaml:

database:
  host: localhost
  port: 5432
  user: postgres
  password: postgres
  dbname: dataset
  sslmode: disable

Or use environment variables:

export DB_HOST=localhost
export DB_PORT=5432
export DB_USER=postgres
export DB_PASSWORD=secret
export DB_NAME=dataset
export LIBSQL_URL=libsql://your-db.turso.io?authToken=your-token

Database Support

| Database | CGO Required | Notes | |-----------|--------------|--------------------------------| | SQLite | No | Default, stores at ~/.dataset-cli/ | | PostgreSQL| No | Use --postgres flag | | TursoDB | No | Cloud SQLite, use --cloud flag |

Shell Completion

# Bash
dataset-cli completion bash >> ~/.bashrc

# Zsh
dataset-cli completion zsh >> ~/.zshrc

# Fish
dataset-cli completion fish > ~/.config/fish/completions/dataset-cli.fish

Development

# Build
make build

# Run tests
go test ./...

# Run with PostgreSQL
make start    # Start PostgreSQL
make run      # Run CLI

License

MIT License - see LICENSE for details.

Links


Made with ❤️ using Go