W3cubDocs

/Nushell

g for shells

Switch to a given shell, or list all shells if no given shell number.

Signature

> g (shell_number)

Parameters

  • shell_number: shell number to change to

Examples

Lists all open shells

>g

Make two directories and enter new shells for them, use g to jump to the specific shell

>mkdirfoobar;enterfoo;enter../bar;g1

Use shells to show all the opened shells and run g 2 to jump to the third one

>shells;g2

Make two directories and enter new shells for them, use g - to jump to the last used shell

>mkdirfoobar;enterfoo;enter../bar;g-

Copyright © 2019–2023 The Nushell Project DevelopersLicensed under the MIT License.
https://www.nushell.sh/commands/docs/g.html