mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-30 03:01:15 -03:00
docs: use :doc: role when referencing entire pages
No need to define "cmd-foo" anchors; use :doc:`foo <cmds/foo>`
instead. If we want "cmd-foo" but it should be tested.
See also 38b24c2325 (docs: Use :doc: role when linking to commands,
2022-09-23).
This commit is contained in:
@@ -919,7 +919,7 @@ Notable improvements and fixes
|
||||
|
||||
which expands ``!!`` to the last history item, anywhere on the command line, mimicking other shells' history expansion.
|
||||
|
||||
See :ref:`the documentation <cmd-abbr>` for more.
|
||||
See :doc:`the documentation <cmds/abbr>` for more.
|
||||
- ``path`` gained a new ``mtime`` subcommand to print the modification time stamp for files. For example, this can be used to handle cache file ages (:issue:`9057`)::
|
||||
|
||||
> touch foo
|
||||
@@ -1344,7 +1344,7 @@ Scripting improvements
|
||||
two
|
||||
'blue '
|
||||
|
||||
- ``$fish_user_paths`` is now automatically deduplicated to fix a common user error of appending to it in config.fish when it is universal (:issue:`8117`). :ref:`fish_add_path <cmd-fish_add_path>` remains the recommended way to add to $PATH.
|
||||
- ``$fish_user_paths`` is now automatically deduplicated to fix a common user error of appending to it in config.fish when it is universal (:issue:`8117`). :doc:`fish_add_path <cmds/fish_add_path>` remains the recommended way to add to $PATH.
|
||||
- ``return`` can now be used outside functions. In scripts, it does the same thing as ``exit``. In interactive mode,it sets ``$status`` without exiting (:issue:`8148`).
|
||||
- An oversight prevented all syntax checks from running on commands given to ``fish -c`` (:issue:`8171`). This includes checks such as ``exec`` not being allowed in a pipeline, and ``$$`` not being a valid variable. Generally, another error was generated anyway.
|
||||
- ``fish_indent`` now correctly reformats tokens that end with a backslash followed by a newline (:issue:`8197`).
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-_:
|
||||
|
||||
_ - call fish's translations
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-abbr:
|
||||
|
||||
abbr - manage fish abbreviations
|
||||
================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-alias:
|
||||
|
||||
alias - create a function
|
||||
=========================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-and:
|
||||
|
||||
and - conditionally execute a command
|
||||
=====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-argparse:
|
||||
|
||||
argparse - parse options passed to a fish script or function
|
||||
============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-begin:
|
||||
|
||||
begin - start a new block of code
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-bg:
|
||||
|
||||
bg - send jobs to background
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-bind:
|
||||
|
||||
bind - handle fish key bindings
|
||||
===============================
|
||||
Synopsis
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-block:
|
||||
|
||||
block - temporarily block delivery of events
|
||||
============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-break:
|
||||
|
||||
break - stop the current inner loop
|
||||
===================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-breakpoint:
|
||||
|
||||
breakpoint - launch debug mode
|
||||
==============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-builtin:
|
||||
|
||||
builtin - run a builtin command
|
||||
===============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-case:
|
||||
|
||||
case - conditionally execute a block of commands
|
||||
================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-cd:
|
||||
|
||||
cd - change directory
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-cdh:
|
||||
|
||||
cdh - change to a recently visited directory
|
||||
============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-command:
|
||||
|
||||
command - run a program
|
||||
=======================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-commandline:
|
||||
|
||||
commandline - set or get the current command line buffer
|
||||
========================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-complete:
|
||||
|
||||
complete - edit command-specific tab-completions
|
||||
================================================
|
||||
|
||||
@@ -16,7 +14,7 @@ Description
|
||||
|
||||
``complete`` defines, removes or lists completions for a command.
|
||||
|
||||
For an introduction to writing your own completions, see :ref:`Writing your own completions <completion-own>` in
|
||||
For an introduction to writing your own completions, see :doc:`Writing your own completions <../completions>` in
|
||||
the fish manual.
|
||||
|
||||
The following options are available:
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-contains:
|
||||
|
||||
contains - test if a word is present in a list
|
||||
==============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-continue:
|
||||
|
||||
continue - skip the remainder of the current iteration of the current inner loop
|
||||
================================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-count:
|
||||
|
||||
count - count the number of elements of a list
|
||||
================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-dirh:
|
||||
|
||||
dirh - print directory history
|
||||
==============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-dirs:
|
||||
|
||||
dirs - print directory stack
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-disown:
|
||||
|
||||
disown - remove a process from the list of jobs
|
||||
===============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-echo:
|
||||
|
||||
echo - display a line of text
|
||||
=============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-else:
|
||||
|
||||
else - execute command if a condition is not met
|
||||
================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-emit:
|
||||
|
||||
emit - emit a generic event
|
||||
===========================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-end:
|
||||
|
||||
end - end a block of commands
|
||||
=============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-eval:
|
||||
|
||||
eval - evaluate the specified commands
|
||||
======================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-exec:
|
||||
|
||||
exec - execute command in current process
|
||||
=========================================
|
||||
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
.. _cmd-exit:
|
||||
.. program::exit
|
||||
|
||||
exit - exit the shell
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-export:
|
||||
|
||||
export - compatibility function for exporting variables
|
||||
=======================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-false:
|
||||
|
||||
false - return an unsuccessful result
|
||||
=====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fg:
|
||||
|
||||
fg - bring job to foreground
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
.. _cmd-fish:
|
||||
.. program::fish
|
||||
|
||||
fish - the friendly interactive shell
|
||||
=====================================
|
||||
|
||||
@@ -18,7 +15,7 @@ Description
|
||||
:command:`fish` is a command-line shell written mainly with interactive use in mind.
|
||||
This page briefly describes the options for invoking :command:`fish`.
|
||||
The :ref:`full manual <intro>` is available in HTML by using the :command:`help` command from inside fish, and in the `fish-doc(1)` man page.
|
||||
The :ref:`tutorial <tutorial>` is available as HTML via ``help tutorial`` or in `man fish-tutorial`.
|
||||
The :doc:`tutorial <../tutorial>` is available as HTML via ``help tutorial`` or in `man fish-tutorial`.
|
||||
|
||||
|
||||
The following options are available:
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
.. _cmd-fish_add_path:
|
||||
.. program::fish_add_path
|
||||
|
||||
fish_add_path - add to the path
|
||||
==============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_breakpoint_prompt:
|
||||
|
||||
fish_breakpoint_prompt - define the prompt when stopped at a breakpoint
|
||||
=======================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_clipboard_copy:
|
||||
|
||||
fish_clipboard_copy - copy text to the system's clipboard
|
||||
==============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_clipboard_paste:
|
||||
|
||||
fish_clipboard_paste - get text from the system's clipboard
|
||||
==============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_command_not_found:
|
||||
|
||||
fish_command_not_found - what to do when a command wasn't found
|
||||
===============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_config:
|
||||
|
||||
fish_config - start the web-based configuration interface
|
||||
=========================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_default_key_bindings:
|
||||
|
||||
fish_default_key_bindings - set emacs key bindings for fish
|
||||
===============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_git_prompt:
|
||||
|
||||
fish_git_prompt - output git information for use in a prompt
|
||||
============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_greeting:
|
||||
|
||||
fish_greeting - display a welcome message in interactive shells
|
||||
===============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_hg_prompt:
|
||||
|
||||
fish_hg_prompt - output Mercurial information for use in a prompt
|
||||
=================================================================
|
||||
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
.. _cmd-fish_indent:
|
||||
.. program::fish_indent
|
||||
|
||||
fish_indent - indenter and prettifier
|
||||
=====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_is_root_user:
|
||||
|
||||
fish_is_root_user - check if the current user is root
|
||||
=====================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_key_reader:
|
||||
|
||||
fish_key_reader - explore what characters keyboard keys send
|
||||
============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_mode_prompt:
|
||||
|
||||
fish_mode_prompt - define the appearance of the mode indicator
|
||||
==============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_opt:
|
||||
|
||||
fish_opt - create an option specification for the argparse command
|
||||
==================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_prompt:
|
||||
|
||||
fish_prompt - define the appearance of the command line prompt
|
||||
==============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_right_prompt:
|
||||
|
||||
fish_right_prompt - define the appearance of the right-side command line prompt
|
||||
===============================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_should_add_to_history:
|
||||
|
||||
fish_should_add_to_history - decide whether a command should be added to the history
|
||||
====================================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_status_to_signal:
|
||||
|
||||
fish_status_to_signal - convert exit codes to human-friendly signals
|
||||
====================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_svn_prompt:
|
||||
|
||||
fish_svn_prompt - output Subversion information for use in a prompt
|
||||
===================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_title:
|
||||
|
||||
fish_title - define the terminal's title
|
||||
========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_update_completions:
|
||||
|
||||
fish_update_completions - update completions using manual pages
|
||||
===============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_vcs_prompt:
|
||||
|
||||
fish_vcs_prompt - output version control system information for use in a prompt
|
||||
===============================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-fish_vi_key_bindings:
|
||||
|
||||
fish_vi_key_bindings - set vi key bindings for fish
|
||||
===============================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-for:
|
||||
|
||||
for - perform a set of commands multiple times
|
||||
==============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-funced:
|
||||
|
||||
funced - edit a function interactively
|
||||
======================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-funcsave:
|
||||
|
||||
funcsave - save the definition of a function to the user's autoload directory
|
||||
=============================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-function:
|
||||
|
||||
function - create a function
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-functions:
|
||||
|
||||
functions - print or erase functions
|
||||
====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-help:
|
||||
|
||||
help - display fish documentation
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-history:
|
||||
|
||||
history - show and manipulate command history
|
||||
=============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-if:
|
||||
|
||||
if - conditionally execute a command
|
||||
====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-isatty:
|
||||
|
||||
isatty - test if a file descriptor is a terminal
|
||||
================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-jobs:
|
||||
|
||||
jobs - print currently running jobs
|
||||
===================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-math:
|
||||
|
||||
math - perform mathematics calculations
|
||||
=======================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-nextd:
|
||||
|
||||
nextd - move forward through directory history
|
||||
==============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-not:
|
||||
|
||||
not - negate the exit status of a job
|
||||
=====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-open:
|
||||
|
||||
open - open file in its default application
|
||||
===========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-or:
|
||||
|
||||
or - conditionally execute a command
|
||||
====================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-path:
|
||||
|
||||
path - manipulate and check paths
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-popd:
|
||||
|
||||
popd - move through directory stack
|
||||
===================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-prevd:
|
||||
|
||||
prevd - move backward through directory history
|
||||
===============================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-printf:
|
||||
|
||||
printf - display text according to a format string
|
||||
==================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-prompt_hostname:
|
||||
|
||||
prompt_hostname - print the hostname, shortened for use in the prompt
|
||||
=====================================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-prompt_login:
|
||||
|
||||
prompt_login - describe the login suitable for prompt
|
||||
=====================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-prompt_pwd:
|
||||
|
||||
prompt_pwd - print pwd suitable for prompt
|
||||
==========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-psub:
|
||||
|
||||
psub - perform process substitution
|
||||
===================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-pushd:
|
||||
|
||||
pushd - push directory to directory stack
|
||||
=========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-pwd:
|
||||
|
||||
pwd - output the current working directory
|
||||
==========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-random:
|
||||
|
||||
random - generate random number
|
||||
===============================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-read:
|
||||
|
||||
read - read line of input into variables
|
||||
========================================
|
||||
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
.. _cmd-realpath:
|
||||
.. program::realpath
|
||||
|
||||
realpath - convert a path to an absolute path without symlinks
|
||||
==============================================================
|
||||
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
.. _cmd-return:
|
||||
.. program::return:
|
||||
|
||||
return - stop the current inner function
|
||||
========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-set:
|
||||
|
||||
set - display and change shell variables
|
||||
========================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-set_color:
|
||||
|
||||
set_color - set the terminal color
|
||||
==================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-source:
|
||||
|
||||
source - evaluate contents of file
|
||||
==================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-status:
|
||||
|
||||
status - query fish runtime information
|
||||
=======================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-string-length:
|
||||
|
||||
string-length - print string lengths
|
||||
====================================
|
||||
|
||||
|
||||
@@ -88,7 +88,7 @@ See Also
|
||||
|
||||
.. BEGIN SEEALSO
|
||||
|
||||
- :ref:`string<cmd-string>`'s ``pad`` subcommand does the inverse of this command, adding padding to a specific width instead.
|
||||
- :doc:`string pad <string-pad>` does the inverse of this command, adding padding to a specific width instead.
|
||||
|
||||
- The :doc:`printf <printf>` command can do simple padding, for example ``printf %10s\n`` works like ``string pad -w10``.
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-string:
|
||||
|
||||
string - manipulate strings
|
||||
===========================
|
||||
|
||||
@@ -51,8 +49,6 @@ Most subcommands accept a **-q** or **--quiet** switch, which suppresses the usu
|
||||
|
||||
The following subcommands are available.
|
||||
|
||||
.. _cmd-string-collect:
|
||||
|
||||
"collect" subcommand
|
||||
--------------------
|
||||
|
||||
@@ -236,9 +232,6 @@ Examples
|
||||
:start-after: BEGIN EXAMPLES
|
||||
:end-before: END EXAMPLES
|
||||
|
||||
.. _cmd-string-split:
|
||||
.. _cmd-string-split0:
|
||||
|
||||
"split" and "split0" subcommands
|
||||
--------------------------------
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-suspend:
|
||||
|
||||
suspend - suspend the current shell
|
||||
===================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-switch:
|
||||
|
||||
switch - conditionally execute a block of commands
|
||||
==================================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-test:
|
||||
|
||||
test - perform tests on files and text
|
||||
======================================
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
.. _cmd-time:
|
||||
|
||||
time - measure how long a command or block takes
|
||||
================================================
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user