clear

For platform.

Clear the terminal screen.

Command Type

built-in

Signature

> clear {flags}

Flags

  • --keep-scrollback, -k: Do not clear the scrollback history.

Input/output types:

input output
nothing nothing

Examples

Clear the terminal.

> clear

Clear the terminal but not its scrollback history.

> clear --keep-scrollback

Notes

By default clears the current screen and the off-screen scrollback buffer.

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