Nushell is a new type of shell, in which pipelines are the base to build SQL-like queries that improve your experience on a terminal.

Nushell also displays the output of some popular commands (like ls) in a colorful and structured way.

Table of Contents

Installation

You can install Nushell from several sources: Homebrew (brew install nushell) , downloading the binaries from https://github.com/nushell/nushell/releases, installing from AUR (on Arch Linux) or compiling the source code. Check Nushell homepage for more info.

Usage

Just run nu to start. Nushell makes super easy to make SQL-like queries to ls. These are some examples:

ls . | where size > 20mb | sort-by modified
ls /usr/bin/ | where size > 10mb          03/25/2022 07:00:22 PM
╭───┬───────────────────────────────────────┬──────┬──────────┬────────────╮
│ # │                 name                  │ type │   size   │  modified  │
├───┼───────────────────────────────────────┼──────┼──────────┼────────────┤
│ 0 │ /usr/bin/clementine                   │ file │ 16.6 MiB │ a year ago │
│ 1 │ /usr/bin/lazpaint                     │ file │ 14.0 MiB │ a year ago │
│ 2 │ /usr/bin/x86_64-linux-gnu-lto-dump-10 │ file │ 23.3 MiB │ a year ago │
╰───┴───────────────────────────────────────┴──────┴──────────┴────────────╯

You can also find and structure info from JSON, CSV, Excel and other file formats.

> cat ./test.csv                         03/25/2022 07:09:40 PM
fechalectura,lectura
2021-06-04,177
2021-08-10,184
2021-10-07,190
2021-12-06,197
2022-02-04,203

> open ./test.csv | get lectura          03/25/2022 07:08:45 PM
╭───┬─────╮
│ 0 │ 177 │
│ 1 │ 184 │
│ 2 │ 190 │
│ 3 │ 197 │
│ 4 │ 203 │
╰───┴─────╯

It has autocompletion that remembers previous commands (similar to zsh and other shells).

Check https://www.nushell.sh/book/ for more info on all Nushell awesome features.

If you have any suggestion, feel free to contact me via social media or email.