System

  • complete — Capture the outputs and exit code from an external piped in command in a nushell table.
  • exec — Execute a command, replacing or exiting the current process, depending on platform.
  • ps — View information about system processes.
  • registry — Various commands for interacting with the system registry (Windows only).
  • registry query — Query the Windows registry.
  • run-external — Runs external command.
  • sys — View information about the system.
  • sys cpu — View information about the system CPUs.
  • sys disks — View information about the system disks.
  • sys host — View information about the system host.
  • sys mem — View information about the system memory.
  • sys net — View information about the system network interfaces.
  • sys temp — View the temperatures of system components.
  • sys users — View information about the users on the system.
  • uname — Print certain system information using uutils/coreutils uname.
  • which — Finds a program file, alias or custom command. If application is not provided, all deduplicated commands will be returned.

Ported from nushell/nushell.github.io. Copyright (c) 2021 Nushell Project. MIT License.

Tips

Intro

sys host includes the hostname.

sys host | get hostname

sys cpu returns one row per cpu.

sys cpu | length

Basic

Measure the hostname.

sys host | get hostname | str length

The cpu row count is a number.

sys cpu | length | math abs

Intermediate

Hostname length, then abs.

sys host | get hostname | str length | math abs

each can visit every cpu row.

sys cpu | each {|c| $c} | length

Advanced

Four steps from the hostname to a count.

sys host | get hostname | str length | into string | str length