Skip to content

Commit

Permalink
Release notes for 0.80 (#890)
Browse files Browse the repository at this point in the history
* Release notes for `0.80`

Please add your new features and breaking changes to the release notes
by opening PRs against the `release-notes-0.80` branch.

* add a bunch of interesting PR links (#903)

* Add quick note about module update

* Update 2023-05-16-nushell_0_80.md

* fix html in PR text

---------

Co-authored-by: Antoine Stevan <[email protected]>
Co-authored-by: Jakub Žádník <[email protected]>
Co-authored-by: JT <[email protected]>
  • Loading branch information
4 people committed May 17, 2023
1 parent aae2f19 commit 49b09b8
Showing 1 changed file with 139 additions and 0 deletions.
139 changes: 139 additions & 0 deletions blog/2023-05-16-nushell_0_80.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
---
title: Nushell 0.80
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 version 0.80 of Nu. This release adds record type annotations, modules from directories, and improvements to the standard library.
---

# Nushell 0.80

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.

Today, we're releasing version 0.80 of Nu. This release adds record type annotations, modules from directories, and improvements to the standard library.

<!-- more -->

# Where to get it

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

NOTE: The optional dataframe functionality is available by `cargo install nu --features=dataframe`.

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>`.

# Themes of this release / New features

## Record type annotations ([@1Kinoti](https://github.com/nushell/nushell/pull/8914))

Starting with this release, you can add more information about the type of a record your command expects. For example:

```
def okay [person: record<name: string age: int>] {}
```

The above will require two fields to be present, a `name` that's a `string, and an `age`that's an`int`. The current version requires that the record has exactly these fields, though we may loosen this in future releases to allow for structural subtyping.

## Modules from directories ([@Kubouch](https://github.com/nushell/nushell/pull/9066))

It is now possible to create a module from a directory. The directory must contain `mod.nu` and all other .nu files are added as a submodule of the module. This allows some traditional shell patterns such as dumping completion files into a directory to be loaded automatically. Check out the newly updated [book chapter](https://www.nushell.sh/book/modules.html) for more details and examples.

The enabling feature for module directories was organizing modules into submodule structure instead of solely relying on re-importing symbols with `export use`. `module` and especially `export module` have been added as a result of this change. While not immediately visible, the module update allows for cleaner submodule oganization without relying on re-exporting symbols with `export use`. Since modules are now aware of their submodules, in the future we hope to improve discoverability of definitions within modules, enhancing our IDE support (such as our [LSP](https://github.com/nushell/vscode-nushell-lang)).

## Stdlib update ([@amtoine, @EmilySeville7cfg, @skelly37, @YummyOreo][std-lib PRs])

| hash | commit | PR |
| --------- | -------------------------------------------------------------- | ----------------------------------------------------- |
| 3268ecd11 | FEATURE: add the `bench` command to the standard library | [#8969](https://github.com/nushell/nushell/pull/8969) |
| 155de9f6f | Added `log custom` command & exported log levels | [#9055](https://github.com/nushell/nushell/pull/9055) |
| edb61fc1d | Try to show help pages for external commands w/ `help` command | [#9025](https://github.com/nushell/nushell/pull/9025) |
| 7a945848d | swap the date and the log level in the `std log` format | [#9138](https://github.com/nushell/nushell/pull/9138) |

## other interesting new features

| hash | commit | PR |
| --------- | ---------------------------------------------------------- | ----------------------------------------------------- |
| e251f3a0b | Change type of parameter default values to `Option<Value>` | [#8940](https://github.com/nushell/nushell/pull/8940) |
| c422c6cc3 | Fix completion on `$nu` to show correct menus | [#8919](https://github.com/nushell/nushell/pull/8919) |
| 44493dac5 | Add extern def which allows raw arguments | [#8956](https://github.com/nushell/nushell/pull/8956) |
| fb10e1dfc | add `--ide-ast` for a simplistic ast for editors | [#8995](https://github.com/nushell/nushell/pull/8995) |
| 4ca47258a | Add --redirect-combine option to run-external | [#8918](https://github.com/nushell/nushell/pull/8918) |
| e590d3587 | enable history isolation | [#9063](https://github.com/nushell/nushell/pull/9063) |
| d45e9671d | Suggest existing variables on not found | [#8902](https://github.com/nushell/nushell/pull/8902) |
| a7c1b363e | Don't run .sh files with /bin/sh | [#8951](https://github.com/nushell/nushell/pull/8951) |
| e4625acf2 | support bracketed paste | [#8907](https://github.com/nushell/nushell/pull/8907) |
| b82e279f9 | REFACTOR: remove deprecated commands (`old-alias`) | [#9056](https://github.com/nushell/nushell/pull/9056) |
| 10d65b611 | adds a list subcommand to input (interactive selections) | [#8963](https://github.com/nushell/nushell/pull/8963) |

# Breaking changes

- [#8940](https://github.com/nushell/nushell/pull/8940) Change type of parameter default values to `Option<Value>`
- [#9007](https://github.com/nushell/nushell/pull/9007) Fix unexpected flattening of data by par-each (Issue #8497)
- [#9056](https://github.com/nushell/nushell/pull/9056) REFACTOR: remove deprecated commands (`old-alias`)

# Full changelog

## Nushell

- sholderbach created [Bump version for 0.80.0 release](https://github.com/nushell/nushell/pull/9212), and [Pin reedline to `0.19.1` for 0.80 release](https://github.com/nushell/nushell/pull/9211)
- stormasm created [document how to run dataframe tests as well](https://github.com/nushell/nushell/pull/9188)
- kubouch created [Allow recursive module dirs; Require mod.nu in dirs](https://github.com/nushell/nushell/pull/9185), and [Reuse parsed modules](https://github.com/nushell/nushell/pull/9125), and [Fix exported module not found](https://github.com/nushell/nushell/pull/9121), and [Allow creating modules from directories](https://github.com/nushell/nushell/pull/9066)
- amtoine created [fix the span of the global `std help` item](https://github.com/nushell/nushell/pull/9184), and [swap the date and the log level in the `std log` format](https://github.com/nushell/nushell/pull/9138), and [FEATURE: add a `main` command to `toolkit.nu`](https://github.com/nushell/nushell/pull/9135), and [REFACTOR: make `input list` a tiny bit tighter](https://github.com/nushell/nushell/pull/9115), and [FIX: have consistent errors between `std help` and `std help ...`](https://github.com/nushell/nushell/pull/9101), and [REFACTOR: fix typos and simplify external `std help`](https://github.com/nushell/nushell/pull/9100), and [pass `std bench` into `table -e` in the example](https://github.com/nushell/nushell/pull/9075), and [FIX: add a space after the default left prompt](https://github.com/nushell/nushell/pull/9074), and [REFACTOR: move `source` out of deprecated commands](https://github.com/nushell/nushell/pull/9060), and [REFACTOR: remove deprecated commands (`old-alias`)](https://github.com/nushell/nushell/pull/9056), and [FEATURE: return tables with `std help ... --find ...`](https://github.com/nushell/nushell/pull/9040), and [FIX: correct bad span in `std help` errors](https://github.com/nushell/nushell/pull/9039), and [FIX: filter the `std help ...` by name, usage and search terms](https://github.com/nushell/nushell/pull/9035), and [FIX: give same order in `std help ...` as in `help ...`](https://github.com/nushell/nushell/pull/9034), and [REFACTOR: have a single `std` loading call](https://github.com/nushell/nushell/pull/9033), and [TRIAGE: add the `needs-triage` to all `ISSUE_TEMPLATE`s](https://github.com/nushell/nushell/pull/9023), and [FEATURE: add `--expand` to `std clip`](https://github.com/nushell/nushell/pull/8970), and [FEATURE: add the `bench` command to the standard library](https://github.com/nushell/nushell/pull/8969), and [REFACTOR: remove the shell commands](https://github.com/nushell/nushell/pull/8415), and [REFACTOR: move the banner from the `rust` source to the standard library](https://github.com/nushell/nushell/pull/8406)
- jntrnr created [remove a few unnecessary allocations](https://github.com/nushell/nushell/pull/9176)
- fdncred created [add dataframe support to toolkit](https://github.com/nushell/nushell/pull/9173), and [Update default_env.nu to work with windows](https://github.com/nushell/nushell/pull/9172), and [add a negation glob option to the glob command](https://github.com/nushell/nushell/pull/9153), and [resolve standard library before ide commands](https://github.com/nushell/nushell/pull/9126), and [update nu-glob based on latest glob 0.3.1 changes](https://github.com/nushell/nushell/pull/9099), and [enable history isolation](https://github.com/nushell/nushell/pull/9063), and [Update rust-toolchain.toml to 1.67.1](https://github.com/nushell/nushell/pull/9012), and [add `--ide-ast` for a simplistic ast for editors](https://github.com/nushell/nushell/pull/8995)
- juanPabloMiceli created [Fix find -v command on tables (issue #9043)](https://github.com/nushell/nushell/pull/9159), and [Fix negative precision round with ints (issue #9049)](https://github.com/nushell/nushell/pull/9073)
- michaeljohnalbers created [Ensure consistent map ordering when reading YAML](https://github.com/nushell/nushell/pull/9155)
- bobhy created [Parameter defaults to $nu.scope.commands](https://github.com/nushell/nushell/pull/9152)
- Hofer-Julian created [Start to move to polars 0.29](https://github.com/nushell/nushell/pull/9145), and [Update polars to 0.28](https://github.com/nushell/nushell/pull/9136)
- tesla232 created [Span fixes during duration conversion](https://github.com/nushell/nushell/pull/9143)
- zhiburt created [nu-explore: Fix repeated char issue in cmdline](https://github.com/nushell/nushell/pull/9139), and [nu-explore: Fix pipeline rendering](https://github.com/nushell/nushell/pull/9137), and [Fix #9038](https://github.com/nushell/nushell/pull/9042)
- 1Kinoti created [add more commands to `std iter`](https://github.com/nushell/nushell/pull/9129), and [make the pattern-matcher and eval engine use the same unit computation](https://github.com/nushell/nushell/pull/8973), and [improve error when name and parameters are not space-separated](https://github.com/nushell/nushell/pull/8958)
- melMass created [chore: ✨ enable setup-git-hooks on windows](https://github.com/nushell/nushell/pull/9097), and [adds a list subcommand to input (interactive selections)](https://github.com/nushell/nushell/pull/8963)
- EmilySeville7cfg created [FEATURE: highlight some prompt parts](https://github.com/nushell/nushell/pull/9094), and [FEATURE: move common functionality to subroutine in `build-all-windows.cmd`](https://github.com/nushell/nushell/pull/9093), and [FEATURE: format `std log` and add `--short` option](https://github.com/nushell/nushell/pull/9091)
- Mehrbod2002 created [Feat: listen for signal on glob command](https://github.com/nushell/nushell/pull/9088)
- WindSoilder created [Fix overlay's help message lead to internal error](https://github.com/nushell/nushell/pull/9087), and [support bracketed paste](https://github.com/nushell/nushell/pull/8907)
- MariaSolOs created [Change type of flag defaults to `Option<Value>`](https://github.com/nushell/nushell/pull/9085)
- skelly37 created [Added `log custom` command & exported log levels](https://github.com/nushell/nushell/pull/9055)
- stevenxxiu created [fix: use `buffer.len()` instead of `cursor_pos`, so the `.expect()` isn't useless](https://github.com/nushell/nushell/pull/9053), and [fix: fix cursor position when cursor is at the end of the commandline](https://github.com/nushell/nushell/pull/9030)
- YummyOreo created [Try to show help pages for external commands w/ `help` command](https://github.com/nushell/nushell/pull/9025)
- TrMen created [Add more examples to `help use`](https://github.com/nushell/nushell/pull/9024)
- hustcer created [Remove npm install instruction](https://github.com/nushell/nushell/pull/9022)
- rgwood created [Slim down tests](https://github.com/nushell/nushell/pull/9021)
- ErichDonGubler created [feat(rm)!: use arg. spans for I/O errors](https://github.com/nushell/nushell/pull/8964)
- pingiun created [Add extern def which allows raw arguments](https://github.com/nushell/nushell/pull/8956), and [Don't run .sh files with /bin/sh](https://github.com/nushell/nushell/pull/8951), and [Add --redirect-combine option to run-external](https://github.com/nushell/nushell/pull/8918)
- schicks created [Suggest existing variables on not found](https://github.com/nushell/nushell/pull/8902)

## Extension

- EmilySeville7cfg created [feat(snippets): markdown doc sections](https://github.com/nushell/vscode-nushell-lang/pull/127), and [feat(snippets): completions](https://github.com/nushell/vscode-nushell-lang/pull/126), and [Feature: add date format snippets](https://github.com/nushell/vscode-nushell-lang/pull/121), and [Feature/add remaining snippets](https://github.com/nushell/vscode-nushell-lang/pull/119), and [Feature/update snippets](https://github.com/nushell/vscode-nushell-lang/pull/116)
- fdncred created [update changelog](https://github.com/nushell/vscode-nushell-lang/pull/124), and [update version and changelog](https://github.com/nushell/vscode-nushell-lang/pull/118)

## Documentation

- mrkkrp created [Minor corrections in variables_and_subexpressions.md](https://github.com/nushell/nushell.github.io/pull/906)
- VuiMuich created [small typo in `dataframes.md`](https://github.com/nushell/nushell.github.io/pull/905)
- amtoine created [add a bunch of interesting PR links](https://github.com/nushell/nushell.github.io/pull/903), and [FIX: add prettier `std` commands format in 0.79 changelog](https://github.com/nushell/nushell.github.io/pull/893), and [fix the "`std` import" section of the 0.79 changelog](https://github.com/nushell/nushell.github.io/pull/892)
- tzemanovic created [book/coming_from_bash - s/hide/hide-env](https://github.com/nushell/nushell.github.io/pull/900)
- maxomatic458 created [update link to job.nu file](https://github.com/nushell/nushell.github.io/pull/897)
- PhilVoel created [Fixed link in design_notes to how_nushell_code_gets_run](https://github.com/nushell/nushell.github.io/pull/895)
- Askerad created [Fixing Tiny Typo - Update aliases.md](https://github.com/nushell/nushell.github.io/pull/894)
- hustcer created [Update npm install instruction](https://github.com/nushell/nushell.github.io/pull/891)

## Nu_Scripts

- EmilySeville7cfg created [Fix: remaining aliases](https://github.com/nushell/nu_scripts/pull/495), and [feat(aliases): reformat and use long options](https://github.com/nushell/nu_scripts/pull/489), and [feat(module): add random-list](https://github.com/nushell/nu_scripts/pull/488), and [Feature: clean-up completion directory](https://github.com/nushell/nu_scripts/pull/484), and [feat(nano): add completions](https://github.com/nushell/nu_scripts/pull/479)
- Tiggax created [Added typst completion script.](https://github.com/nushell/nu_scripts/pull/494)
- nullishamy created [fix: just completions](https://github.com/nushell/nu_scripts/pull/491)
- fj0r created [gp: run `git fetch` before `git push` or `git pull`](https://github.com/nushell/nu_scripts/pull/490), and [kubernetes completion of jsonpath](https://github.com/nushell/nu_scripts/pull/487), and [clean up kubernetes.nu](https://github.com/nushell/nu_scripts/pull/486), and [improve kconf import](https://github.com/nushell/nu_scripts/pull/481), and [rename registry list to registry show](https://github.com/nushell/nu_scripts/pull/480), and [Fix the problem that the file KUBECONFIG points does not exist](https://github.com/nushell/nu_scripts/pull/476), and [refactor powerline script](https://github.com/nushell/nu_scripts/pull/471), and [optimize kube_stat with ensure-cache](https://github.com/nushell/nu_scripts/pull/470), and [refactor left_prompt decorator logic](https://github.com/nushell/nu_scripts/pull/469), and [atuin](https://github.com/nushell/nu_scripts/pull/468)
- zsehanovic created [fix git aliases](https://github.com/nushell/nu_scripts/pull/485)
- dschrempf created [ultimate_extractor: various fixes](https://github.com/nushell/nu_scripts/pull/482)
- maxim-uvarov created [the function to display bars of given percentage from given width](https://github.com/nushell/nu_scripts/pull/478)
- RickCogley created [Nupass par each threads 20230504](https://github.com/nushell/nu_scripts/pull/477), and [Nupass performance 20230502](https://github.com/nushell/nu_scripts/pull/474), and [Nupass refactor 20230501](https://github.com/nushell/nu_scripts/pull/473)
- LiHRaM created [Fix npm-completions: move extern declaration below dependent declarations](https://github.com/nushell/nu_scripts/pull/475)
- amtoine created [REFACTOR: unify git modules and aliases](https://github.com/nushell/nu_scripts/pull/472)

## reedline

- TrMen created [Allow binding of `CTRL+ALT+<c>`, `SHIFT+<c>` and `CTRL+ALT+SHIFT+<c>`](https://github.com/nushell/reedline/pull/580)
- WindSoilder created [fix bracketed paste](https://github.com/nushell/reedline/pull/577)
- samlich created [History filter](https://github.com/nushell/reedline/pull/566)

0 comments on commit 49b09b8

Please sign in to comment.