Home Explore Blog CI



nushell

1st chunk of `blog/2021-06-01-nushell_0_32.md`
45f3faa0a5ca5e34250d53d69287d29a5e39deea284b55ec000000010000100d
---
title: Nushell 0.32
author: The Nu Authors
author_site: https://twitter.com/nu_shell
author_image: https://www.nushell.sh/blog/images/nu_logo.png
excerpt: Today, we're releasing 0.32 of Nu. This release contains a large amount of usability improvements.
---

# Nushell 0.32

Nushell, or Nu for short, is a new shell that takes a modern, structured approach to your commandline. It works seamlessly with the data from your filesystem, operating system, and a growing number of file formats to make it easy to build powerful commandline pipelines.

Today, we're releasing 0.32 of Nu. This release contains a large amount of usability improvements.

<!-- more -->

# Where to get it

Nu 0.32 is available as [pre-built binaries](https://github.com/nushell/nushell/releases/tag/0.32.0) or from [crates.io](https://crates.io/crates/nu). If you have Rust installed you can install it using `cargo install nu`.

If you want all the goodies, you can install `cargo install nu --features=extra`.

If you'd like to try the experimental paging feature in this release, you can install with `cargo install nu --features=table-pager`.

As part of this release, we also publish a set of plugins you can install and use with Nu. To install, use `cargo install nu_plugin_<plugin name>`.

# What's New

There are a _lot_ of new changes in this release of Nu. You can check these out by in this blog post, or, if you like, there is also an accompanying [YouTube video of 0.32 features](https://youtu.be/AqYxhJKblvY) as well as updated [Nushell samples](https://github.com/nushell/nu_scripts).

## New expression syntax (sophiajt)

We've simplified our expression/subexpression logic to make it much more predictable and universal. The parser will now automatically handle by command calls and expressions in the same way, so that you don't have to remember to use `=` to switch from one mode to the next.

Before 0.32:

```shell
> = 10 + 3
13
```

With 0.32:

```shell
> 10 + 3
13
```

You can also use any value as an expression, including variables or strings:

```shell
> "hello world"
hello world
```

Subexpressions also follow a similar simplification. We've removed the previous `$()` style, replacing it with `()`. This allows you to put subexpressions anywhere that you want.

```shell
> 10 * (3 + 2)
50
```

```shell
> echo ((ls | length) / 2)
7
```

This allows parens to mean "do this first" in both math expression and command calls.

## Subexpressions and column paths (sophiajt)

The new subexpressions can also use "column paths", or paths that start from the current value and travel to a subset of the structured data inside.

For example, you could combine column paths with some subtraction to find when you last booted your system:

```shell
> (date now) - (sys).host.uptime
2021-05-31 09:00:24.124736365 +12:00
```

## New string interpolation (sophiajt)

We've also updated string interpolation to match the expression/subexpression simplification mentioned above. The same "parens mean do this first" pattern applies:

```shell
> $"the result is (3 + 2)"
the result is 5
```

For interpolation that uses column paths, wrap the entire column path in a pair of parens:

```shell
> $"uptime is (sys).host.uptime"
uptime is [row host cpu mem temp].host.uptime

> $"uptime is ((sys).host.uptime)"
uptime is 1day 19hr 57min 7sec
```

As part of this change, we removed the previous backtick string interpolation form.

## Environment loading (lily-mara)

In Nushell, we've worked hard to limit the amount of mutation that will happen in the system. This helps developers focus on the task at hand, and not have to think about non-local effects from the code they're running.

At the same time, we've also wanted to support virtual environment systems like `virtualenv`, `conda`, and others. Traditionally these systems updated the global environment from inside of their activate/deactivate commands.

With 0.32, we feel like we've managed to come up with a solution that meets both the Nushell philosophy of limiting mutation while also giving the freedom to port virtual environment scripts to Nushell.

Title: Nushell 0.32 Release: Usability Improvements, Expression Syntax, and Environment Loading
Summary
Nushell 0.32 focuses on usability improvements. It introduces simplified expression syntax, removing the need for '=' in many cases and using '()' for subexpressions. Column paths can now be used within these subexpressions. String interpolation has been updated to align with the new expression syntax, using parens for evaluation. Additionally, the release provides a new approach to environment loading, balancing Nushell's philosophy of limited mutation with the need to support virtual environment systems.