mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-29 06:13:20 +00:00
3a23fdf359
Includes harmonizing the display of options and arguments, standardising terminology, using the envvar directive more broadly, adding help options to all commands that support them, simplifying some language, and tidying up multiple formatting issues. string documentation is not changed.
30 lines
1,016 B
ReStructuredText
30 lines
1,016 B
ReStructuredText
.. _cmd-cdh:
|
|
|
|
cdh - change to a recently visited directory
|
|
============================================
|
|
|
|
Synopsis
|
|
--------
|
|
|
|
.. synopsis::
|
|
|
|
cdh [DIRECTORY]
|
|
|
|
Description
|
|
-----------
|
|
|
|
``cdh`` with no arguments presents a list of :ref:`recently visited directories <directory-history>`.
|
|
You can then select one of the entries by letter or number.
|
|
You can also press :kbd:`Tab` to use the completion pager to select an item from the list.
|
|
If you give it a single argument it is equivalent to ``cd DIRECTORY``.
|
|
|
|
Note that the ``cd`` command limits directory history to the 25 most recently visited directories.
|
|
The history is stored in the :envvar:`dirprev` and :envvar:`$dirnext` variables, which this command manipulates.
|
|
If you make those universal variables, your ``cd`` history is shared among all fish instances.
|
|
|
|
See Also
|
|
--------
|
|
|
|
- the :ref:`dirh <cmd-dirh>` command to print the directory history
|
|
- the :ref:`prevd <cmd-prevd>` command to move backward
|
|
- the :ref:`nextd <cmd-nextd>` command to move forward
|