TL;DR — Quick Summary
Nushell is a modern shell where everything is structured data. Pipelines work with tables instead of text, built-in JSON/CSV/YAML support, and type-safe commands.
Nushell reimagines what a shell should be. Instead of piping text between commands that you parse with grep and awk, everything is structured data — tables, records, lists. It’s like having a database query language as your shell.
Installation
# macOS
brew install nushell
# Arch Linux
sudo pacman -S nushell
# Cargo
cargo install nu
# Start Nushell
nu
Structured Data Everywhere
# ls returns a table, not text
> ls
╭───┬────────────┬──────┬──────────┬───────────╮
│ # │ name │ type │ size │ modified │
├───┼────────────┼──────┼──────────┼───────────┤
│ 0 │ README.md │ file │ 2.1KB │ yesterday │
│ 1 │ src │ dir │ 4.0KB │ today │
│ 2 │ Cargo.toml │ file │ 512B │ last week │
╰───┴────────────┴──────┴──────────┴───────────╯
# Filter, sort, select
> ls | where size > 1kb | sort-by size --reverse | select name size
> ps | where cpu > 5 | select name cpu mem
# Open and query data files
> open data.json | select name age | where age > 25
> open sales.csv | group-by region | get "North America"
Pipeline Operations
# SQL-like operations on any data
> ls | where type == "file" | sort-by modified | last 5
> ps | where name =~ "node" | select pid name cpu mem
> sys | get host
> http get https://api.github.com/repos/nushell/nushell | get stargazers_count
# Math and aggregation
> ls | get size | math sum
> [1 2 3 4 5] | math avg
# String operations
> "Hello, World!" | str downcase | split chars | length
Data Format Support
# Built-in parsers for common formats
> open config.yaml
> open data.json
> open report.csv
> open settings.toml
> open data.xlsx
# Convert between formats
> open data.csv | to json
> open config.json | to yaml
# Parse from external commands
> curl -s https://api.example.com | from json | select name
Comparison
| Feature | Nushell | Bash | Zsh | Fish | PowerShell |
|---|---|---|---|---|---|
| Data type | Structured | Text | Text | Text | Objects |
| Pipelines | Tables | Text | Text | Text | Objects |
| Built-in data | JSON/CSV/YAML | No | No | No | XML/JSON |
| Type safety | Yes | No | No | No | Partial |
| Completions | Typed | Basic | Plugins | Built-in | Typed |
| Cross-platform | Yes | Unix | Unix | Unix | Yes |
| Language | Rust | C | C | C++ | C# |
Summary
- Nushell outputs structured data (tables) instead of text — no more grep/awk/sed
- SQL-like operations: where, select, sort-by, group-by, math
- Built-in JSON, CSV, YAML, TOML, and Excel parsing
- Cross-platform: Linux, macOS, Windows
- Rich type system with helpful error messages