Jump to content

Nushell

From Wikipedia, the free encyclopedia
nushell
Original author(s)Sophia Turner, Yehuda Katz
Developer(s)Nushell Project[1]
Initial release2019; 5 years ago (2019)
Written inRust
Operating systemCross-platform
TypeUnix shell
LicenseMIT License[2]
Websitewww.nushell.sh

Nushell (or just Nu for short) is a cross-platform shell that can be used as an interactive login shell and as a command interpreter for shell scripting.

Nushell was created by Sophia Turner and Yehuda Katz in 2019. Inspired by the structured, functional approach of PowerShell but with clear error messages and cross-platform.

History

[edit]

Nushell was conceived as an attempt to bring structured data and modern programming ideas to the traditional Unix shell environment. Its creation was sparked by the success of PowerShell, which introduced the idea of operating on objects rather than plain text streams.

The initial concept was developed by Yehuda Katz and a small group of contributors who were inspired by PowerShell's capabilities but wanted a more functional approach.[3] The team aimed to design a cross-platform shell that could run on Windows, Linux, and macOS, while providing features not found in existing shells like Bash or Zsh.[4][better source needed]

Nushell's first public preview came in 2019.[5] The project gained momentum as it continued to evolve with new features such as pipelines with structured data and customizable plugins.

Features

[edit]
Nushell autocompletion
Nushell initial config

Nu draws inspiration from projects like PowerShell, functional programmingand modern CLI tools. Rather than thinking of files and data as raw streams of text, Nu looks at each input as something with structure. For example, when you list the contents of a directory what you get back is a table of rows, where each row represents an item in that directory. These values can be piped through a series of steps, in a series of commands called a 'pipeline'. Features include:

  • Native syntax highlighting.
  • Native autocomplete.
  • Nu allows commands to output to stdout and read from stdin. Additionally, commands can output structured data (you can think of this as a third kind of stream). Commands that work in the pipeline fit into one of three categories: commands that produce a stream (e.g., ls), commands that filter a stream (e.g., where type == "dir") and commands that consume the output of the pipeline (e.g., table).
  • Nu can load file and URL contents as raw text or structured data (if it recognizes the format)
  • Nu supports plugins that offer additional functionality to the shell and follow the same structured data model that built-in commands use. The awesome-nu repo lists a variety of nu-plugins.

See also

[edit]

References

[edit]
  1. ^ "Nushell Project on GitHub".
  2. ^ "MIT License".
  3. ^ "First blog post".
  4. ^ Minhas, Manpreet Singh (Mar 7, 2023). "Nushell: The only shell you will ever need". Medium. Retrieved Oct 4, 2024.{{cite web}}: CS1 maint: url-status (link)
  5. ^ "First public preview on GitHub".
[edit]