Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
83 changes: 79 additions & 4 deletions blog/2024-09-17-nushell_0_98_0.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,15 @@ author_site: https://twitter.com/nu_shell
author_image: https://www.nushell.sh/blog/images/nu_logo.png
excerpt: Today, we're releasing version 0.98.0 of Nu. This release adds...
---

<!-- TODO: complete the excerpt above -->

# Nushell 0.98.0

Nushell, or Nu for short, is a new shell that takes a modern, structured approach to your command line. 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 command line pipelines.

<!-- TODO: write this excerpt -->

Today, we're releasing version 0.98.0 of Nu. This release adds...

# Where to get it
Expand All @@ -21,6 +23,7 @@ Nu 0.98.0 is available as [pre-built binaries](https://github.com/nushell/nushel
As part of this release, we also publish a set of optional plugins you can install and use with Nu. To install, use `cargo install nu_plugin_<plugin name>`.

# Table of content

- [_Highlights and themes of this release_](#highlights-and-themes-of-this-release-toc)
- [_Changes to commands_](#changes-to-commands-toc)
- [_Additions_](#additions-toc)
Expand Down Expand Up @@ -49,6 +52,7 @@ As part of this release, we also publish a set of optional plugins you can insta
-->

# Highlights and themes of this release [[toc](#table-of-content)]

<!-- NOTE: if you wanna write a section about a breaking change, when it's a very important one,
please add the following snippet to have a "warning" banner :)
> see [an example](https://www.nushell.sh/blog/2023-09-19-nushell_0_85_0.html#pythonesque-operators-removal)
Expand All @@ -63,18 +67,86 @@ As part of this release, we also publish a set of optional plugins you can insta
for the list of available *containers*
-->

## Removing support for the system clipboard

With [#13694](https://github.com/nushell/nushell/pull/13694), support for the system clipboard in keybinds has been removed, as this is not something that we think we can provide good, cross-platform support for in a secure manner. Namely,

- Tests for the clipboard feature are lacking due to the difficulty in setting up tests on each platform.
- The clipboard feature is known to be problematic on certain systems, potentially affecting startup times. Due to the lack of tests, other unfound issues may be lurking.
- The system clipboard adds a potential attack surface.
- The clipboard feature adds 1MB to the binary size.

So, going forward, users that want the system clipboard functionality will have to compile a custom build of nushell by enabling the `system-clipboard` cargo feature. As an alternative, we recommend users delegate system clipboard handling to their terminal.

# Changes to commands [[toc](#table-of-content)]

## Additions [[toc](#table-of-content)]

### `metadata access`

Thanks to [@Bahex](https://github.com/Bahex) in [#13785](https://github.com/nushell/nushell/pull/13785), a new `metadata access` command was added. It takes a closure argument, and the first argument to the closure will be the metadata record. Additionally, the pipeline input to `metadata access` will be forwarded to the closure as is. So, unlike the `metadata` command, this new command allows you to get the metadata of a pipeline without consuming the pipeline.

### `split column --numbered`

Thanks to [@nome](https://github.com/nome) in [#13831](https://github.com/nushell/nushell/pull/13831), a `--numbered` flag was added to `split column` which limits the number of times to split the input string (just like `split row --numbered`).

## Breaking changes [[toc](#table-of-content)]

### `into record`

In [#13637](https://github.com/nushell/nushell/pull/13637), several changes/improvements were made to list inputs for `into record`:

- A list of pairs of values will be converted into a record. For example:
```nushell
[[a 1] [b 2]] | into record
# { a: 1, b: 2 }
```
- A list of records are merged into a single record (records at the end of the list have precedence):
```nushell
[{ a: 1 } { b: 2 } { a: 3 }] | into record
# { a: 3, b: 2 }
```

As a consequence, the previous behavior for list inputs has been removed (the index of each item would be used as the key). Instead, this old behavior can now be accomplished through either of the following:

```nushell
0.. | zip $list | into record

$list | enumerate | transpose -r -d | into record
```

Additionally, `into record` no longer supports range values as input.

After [#13650](https://github.com/nushell/nushell/pull/13650), `into record` also now outputs `millisecond`, `microsecond`, and `nanosecond` columns when provided with a datetime value.

### `clear`

In [#13821](https://github.com/nushell/nushell/pull/13821), [@T3sT3ro](https://github.com/T3sT3ro) changed the `clear` command to clear the entire scrollback buffer. As such, the `--all` flag was removed, since it is now the default behavior. Instead, a `--keep-scrollback` flag was added, which when used, makes `clear` clear only the terminal (the previous default behavior).

### `path exists`

After [#13763](https://github.com/nushell/nushell/pull/13763), if an I/O error occurs when checking if a path exists, `false` is now returned instead of throwing an error (this includes errors due to insufficient permissions).

## Deprecations [[toc](#table-of-content)]

## Removals [[toc](#table-of-content)]

### `str deunicode`

In [#13693](https://github.com/nushell/nushell/pull/13693), the `str deunicode` command (added in v0.96.0) has been removed due to concerns with stability and support post v1.0.

## Bug fixes and other changes [[toc](#table-of-content)]

### `find`

After [#13848](https://github.com/nushell/nushell/pull/13848), the find command no longer strips tabs from its input.

Also, regex patterns are now properly escaped after [#13792](https://github.com/nushell/nushell/pull/13792).

### `detect columns`

One source of panics was fixed in [#13752](https://github.com/nushell/nushell/pull/13752).

<!-- NOTE: to start investigating the contributions of last release, i like to list them all in a raw table.
to achieve this, one can use the [`list-merged-prs` script from `nu_scripts`](https://github.com/nushell/nu_scripts/blob/main/make_release/release-note/list-merged-prs)
as follows:
Expand Down Expand Up @@ -103,6 +175,7 @@ As part of this release, we also publish a set of optional plugins you can insta
-->

# All breaking changes [[toc](#table-of-content)]

<!-- TODO:
paste the output of
```nu
Expand All @@ -117,15 +190,17 @@ As part of this release, we also publish a set of optional plugins you can insta

Thanks to all the contributors below for helping us solve issues and improve documentation :pray:

| author | title | url |
| ------------------------------------ | ----------- | ------------------------------------------------------- |
| [@author](https://github.com/author) | ... | [#12345](https://github.com/nushell/nushell/pull/12345) |
| author | title | url |
| ------------------------------------------------ | ------------------------- | ------------------------------------------------------- |
| [@author](https://github.com/author) | ... | [#12345](https://github.com/nushell/nushell/pull/12345) |
| [@poliorcetics](https://github.com/poliorcetics) | doc: fix broken doc links | [#13644](https://github.com/nushell/nushell/pull/13644) |

# Full changelog [[toc](#table-of-content)]

<!-- TODO:
paste the output of
```nu
./make_release/release-note/get-full-changelog
```
here
-->
-->