Switch \fish sections to rst format

This commit is contained in:
ridiculousfish
2018-12-18 19:14:04 -08:00
parent c33d1a217c
commit 2a002a4ba1
53 changed files with 993 additions and 693 deletions

View File

@@ -85,31 +85,34 @@ In assignment mode, `set` does not modify the exit status. This allows simultane
Examples
------------
\fish
# Prints all global, exported variables.
set -xg
# Sets the value of the variable $foo to be 'hi'.
set foo hi
# Appends the value "there" to the variable $foo.
set -a foo there
::
# Does the same thing as the previous two commands the way it would be done pre-fish 3.0.
set foo hi
set foo $foo there
# Prints all global, exported variables.
set -xg
# Sets the value of the variable $foo to be 'hi'.
set foo hi
# Appends the value "there" to the variable $foo.
set -a foo there
# Does the same thing as the previous two commands the way it would be done pre-fish 3.0.
set foo hi
set foo $foo there
# Removes the variable $smurf
set -e smurf
# Changes the fourth element of the $PATH array to ~/bin
set PATH[4] ~/bin
# Outputs the path to Python if `type -p` returns true.
if set python_path (type -p python)
echo "Python is at $python_path"
end
# Removes the variable $smurf
set -e smurf
# Changes the fourth element of the $PATH array to ~/bin
set PATH[4] ~/bin
# Outputs the path to Python if `type -p` returns true.
if set python_path (type -p python)
echo "Python is at $python_path"
end
\endfish
Notes
------------