History
history— Get the command history.history import— Import command line history.history session— Get the command history session.
Ported from nushell/nushell.github.io. Copyright (c) 2021 Nushell Project. MIT License.
Tips
Intro
history lists commands from this shell.
history | length
history session is the current session id.
history session | into string
Basic
The history length is a number.
history | length | math abs
Measure the session id text.
history session | into string | str length
Intermediate
Count the history, then count that text.
history | length | into string | str length
Filter the history column names.
history | columns | where {|c| $c != ""} | length
Advanced
Four steps from the history length.
history | length | into string | str length | math abs