mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-26 10:43:47 +08:00
Document ctrl-r harder, add something on set -x
This commit is contained in:
parent
5fe43accef
commit
18df41e5e6
|
@ -154,7 +154,9 @@ in :ref:`config.fish <configuration>`.
|
|||
|
||||
How do I run a command from history?
|
||||
------------------------------------
|
||||
Type some part of the command, and then hit the :kbd:`↑` (up) or :kbd:`↓` (down) arrow keys to navigate through history matches. Additional default key bindings include :kbd:`Control`\ +\ :kbd:`P` (up) and :kbd:`Control`\ +\ :kbd:`N` (down). See :ref:`Searchable command history <history-search>` for more information.
|
||||
Type some part of the command, and then hit the :kbd:`↑` (up) or :kbd:`↓` (down) arrow keys to navigate through history matches, or press :kbd:`Control`\ +\ :kbd:`R` to open the history in a searchable pager (and press :kbd:`Control`\ +\ :kbd:`S` to move to older history).
|
||||
|
||||
Additional default key bindings include :kbd:`Control`\ +\ :kbd:`P` (up) and :kbd:`Control`\ +\ :kbd:`N` (down). See :ref:`Searchable command history <history-search>` for more information.
|
||||
|
||||
Why doesn't history substitution ("!$" etc.) work?
|
||||
--------------------------------------------------
|
||||
|
|
|
@ -446,3 +446,11 @@ By now it has become apparent that fish puts much more of a focus on its builtin
|
|||
- :ref:`status <cmd-status>` provides information about the shell status, e.g. if it's interactive or what the current linenumber is. This replaces ``$-`` and ``$BASH_LINENO`` and other variables.
|
||||
|
||||
- ``seq(1)`` can be used as a replacement for ``{1..10}`` range expansion. If your OS doesn't ship a ``seq`` fish includes a replacement function.
|
||||
|
||||
Other facilities
|
||||
----------------
|
||||
|
||||
Bash has ``set -x`` or ``set -o xtrace`` to print all commands that are being executed. In fish, this would be enabled by setting :envvar:`fish_trace`.
|
||||
|
||||
Or, if your intention is to *profile* how long each line of a script takes, you can use ``fish --profile`` - see the :ref:`page for the fish command <cmd-fish>`.
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user