docs: fix typos and grammar in documentation (#2604)

This commit is contained in:
CatsDeservePets authored and GitHub committed 2026-05-30 03:21:55 +02:00
1 parent d6eebeb8ad
commit c53aacf373
3 files changed
+25 -25

No files matched your search

+6 -6
View File
@@ -68,7 +68,7 @@ Use the config file at *path* instead of the normal search locations. This only
**-print-last-dir** **-print-last-dir**
Print the last directory to stdout when lf exits. This can be used to let lf change your shells working directory. See `CHANGING DIRECTORY` for more details. Print the last directory to stdout when lf exits. This can be used to let lf change your shell's working directory. See `CHANGING DIRECTORY` for more details.
**-last-dir-path** *path* **-last-dir-path** *path*
@@ -1071,7 +1071,7 @@ Allow previews to be generated in advance using the `previewer` script as the us
List of attributes that are preserved when copying files. List of attributes that are preserved when copying files.
Currently supported attributes are `mode` (i.e. access mode) and `timestamps` (i.e. modification time and access time). Currently supported attributes are `mode` (i.e. access mode) and `timestamps` (i.e. modification time and access time).
Note that preserving other attributes like ownership of change/birth timestamp is desirable, but not portably supported in Go. Note that preserving other attributes like ownership or change/birth timestamps is desirable, but not portably supported in Go.
## preview (bool) (default true) ## preview (bool) (default true)
@@ -1997,7 +1997,7 @@ Since the preview script is called for each file selection change, it may not ge
To deal with this, the `preload` option can be set to enable file previews to be preloaded in advance. To deal with this, the `preload` option can be set to enable file previews to be preloaded in advance.
If enabled, the preview script will be run on files in advance as the user navigates through them. If enabled, the preview script will be run on files in advance as the user navigates through them.
In this case, if the exit code of the preview script is zero, then the output will be cached in memory and displayed by lf (useful for text or sixel previews). In this case, if the exit code of the preview script is zero, then the output will be cached in memory and displayed by lf (useful for text or sixel previews).
Otherwise, it will fallback to calling the preview script again when the file is actually selected (useful for previews managed by an external program). Otherwise, it will fall back to calling the preview script again when the file is actually selected (useful for previews managed by an external program).
# CHANGING DIRECTORY # CHANGING DIRECTORY
@@ -2036,7 +2036,7 @@ You can add an extra call to make it run on startup as well:
cmd on-cd &{{ ... }} cmd on-cd &{{ ... }}
on-cd on-cd
Note that all shell commands are possible but `%` and `&` are usually more appropriate as `$` and `!` causes flickers and pauses respectively. Note that all shell command types can be used, but `%` and `&` are usually more appropriate, as `$` and `!` cause flickering and pauses respectively.
There is also a `pre-cd` command, that works like `on-cd`, but is run before the directory is actually changed. There is also a `pre-cd` command, that works like `on-cd`, but is run before the directory is actually changed.
Another related command is `on-load` which gets executed when loading a directory. Another related command is `on-load` which gets executed when loading a directory.
@@ -2127,7 +2127,7 @@ Lastly, you may also want to configure the colors of the prompt line to match th
Colors of the prompt line can be configured using the `promptfmt` option which can include hardcoded colors as ANSI escapes. Colors of the prompt line can be configured using the `promptfmt` option which can include hardcoded colors as ANSI escapes.
See the default value of this option to have an idea about how to color this line. See the default value of this option to have an idea about how to color this line.
It is worth noting that lf uses as many colors advertised by your terminal's entry in terminfo or infocmp databases on your system. It is worth noting that lf uses as many colors as advertised by your terminal's entry in terminfo or infocmp databases on your system.
If an entry is not present, it falls back to an internal database. If an entry is not present, it falls back to an internal database.
If your terminal supports 24-bit colors but either does not have a database entry or does not advertise all capabilities, you can enable support by setting the `$COLORTERM` variable to `truecolor` or ensuring `$TERM` is set to a value that ends with `-truecolor`. If your terminal supports 24-bit colors but either does not have a database entry or does not advertise all capabilities, you can enable support by setting the `$COLORTERM` variable to `truecolor` or ensuring `$TERM` is set to a value that ends with `-truecolor`.
@@ -2225,7 +2225,7 @@ https://en.wikipedia.org/wiki/ANSI_escape_code
Icons are configured using `LF_ICONS` environment variable or an icons file (refer to the [CONFIGURATION section](https://github.com/gokcehan/lf/blob/master/doc.md#configuration)). Icons are configured using `LF_ICONS` environment variable or an icons file (refer to the [CONFIGURATION section](https://github.com/gokcehan/lf/blob/master/doc.md#configuration)).
The variable uses the same syntax as `LS_COLORS/LF_COLORS`. The variable uses the same syntax as `LS_COLORS/LF_COLORS`.
Instead of colors, you should use single characters or symbols as values. Instead of colors, you should use single characters or symbols as values.
The `ln` entry supports the special value `target`, which will use the link target to select a icon. Filename rules will still apply based on the link's name -- this mirrors GNU's `ls` and `dircolors` behavior. The `ln` entry supports the special value `target`, which will use the link target to select an icon. Filename rules will still apply based on the link's name -- this mirrors GNU's `ls` and `dircolors` behavior.
The icons file (refer to the [CONFIGURATION section](https://github.com/gokcehan/lf/blob/master/doc.md#configuration)) should consist of whitespace-separated arrays with a `#` character to start comments until the end of the line. The icons file (refer to the [CONFIGURATION section](https://github.com/gokcehan/lf/blob/master/doc.md#configuration)) should consist of whitespace-separated arrays with a `#` character to start comments until the end of the line.
Each line should contain 1-3 columns: a file type or file name pattern, the icon, and an optional icon color. Using only one column disables all rules for that type or name. Each line should contain 1-3 columns: a file type or file name pattern, the icon, and an optional icon color. Using only one column disables all rules for that type or name.
Do not forget to add `set icons true` to your `lfrc` to see the icons. Do not forget to add `set icons true` to your `lfrc` to see the icons.
+7 -7
View File
@@ -66,7 +66,7 @@ SHELL INTEGRATION
-print-last-dir -print-last-dir
Print the last directory to stdout when lf exits. This can be used Print the last directory to stdout when lf exits. This can be used
to let lf change your shells working directory. See to let lf change your shell's working directory. See
CHANGING DIRECTORY for more details. CHANGING DIRECTORY for more details.
-last-dir-path path -last-dir-path path
@@ -1160,7 +1160,7 @@ preserve ([]string) (default mode)
List of attributes that are preserved when copying files. Currently List of attributes that are preserved when copying files. Currently
supported attributes are mode (i.e. access mode) and timestamps (i.e. supported attributes are mode (i.e. access mode) and timestamps (i.e.
modification time and access time). Note that preserving other modification time and access time). Note that preserving other
attributes like ownership of change/birth timestamp is desirable, but attributes like ownership or change/birth timestamps is desirable, but
not portably supported in Go. not portably supported in Go.
preview (bool) (default true) preview (bool) (default true)
@@ -2235,7 +2235,7 @@ previews to be preloaded in advance. If enabled, the preview script will
be run on files in advance as the user navigates through them. In this be run on files in advance as the user navigates through them. In this
case, if the exit code of the preview script is zero, then the output case, if the exit code of the preview script is zero, then the output
will be cached in memory and displayed by lf (useful for text or sixel will be cached in memory and displayed by lf (useful for text or sixel
previews). Otherwise, it will fallback to calling the preview script previews). Otherwise, it will fall back to calling the preview script
again when the file is actually selected (useful for previews managed by again when the file is actually selected (useful for previews managed by
an external program). an external program).
@@ -2281,8 +2281,8 @@ You can add an extra call to make it run on startup as well:
cmd on-cd &{{ ... }} cmd on-cd &{{ ... }}
on-cd on-cd
Note that all shell commands are possible but % and & are usually more Note that all shell command types can be used, but % and & are usually
appropriate as $ and ! causes flickers and pauses respectively. more appropriate, as $ and ! cause flickering and pauses respectively.
There is also a pre-cd command, that works like on-cd, but is run before There is also a pre-cd command, that works like on-cd, but is run before
the directory is actually changed. Another related command is on-load the directory is actually changed. Another related command is on-load
@@ -2387,7 +2387,7 @@ configured using the promptfmt option which can include hardcoded colors
as ANSI escapes. See the default value of this option to have an idea as ANSI escapes. See the default value of this option to have an idea
about how to color this line. about how to color this line.
It is worth noting that lf uses as many colors advertised by your It is worth noting that lf uses as many colors as advertised by your
terminal's entry in terminfo or infocmp databases on your system. If an terminal's entry in terminfo or infocmp databases on your system. If an
entry is not present, it falls back to an internal database. If your entry is not present, it falls back to an internal database. If your
terminal supports 24-bit colors but either does not have a database terminal supports 24-bit colors but either does not have a database
@@ -2500,7 +2500,7 @@ Icons are configured using LF_ICONS environment variable or an icons
file (refer to the CONFIGURATION section). The variable uses the same file (refer to the CONFIGURATION section). The variable uses the same
syntax as LS_COLORS/LF_COLORS. Instead of colors, you should use single syntax as LS_COLORS/LF_COLORS. Instead of colors, you should use single
characters or symbols as values. The ln entry supports the special value characters or symbols as values. The ln entry supports the special value
target, which will use the link target to select a icon. Filename rules target, which will use the link target to select an icon. Filename rules
will still apply based on the link's name -- this mirrors GNU's ls and will still apply based on the link's name -- this mirrors GNU's ls and
dircolors behavior. The icons file (refer to the CONFIGURATION section) dircolors behavior. The icons file (refer to the CONFIGURATION section)
should consist of whitespace-separated arrays with a # character to should consist of whitespace-separated arrays with a # character to
+12 -12
View File
@@ -1,6 +1,6 @@
.\" Automatically generated by Pandoc 3.7.0.2 .\" Automatically generated by Pandoc 3.7.0.2
.\" .\"
.TH "LF" "1" "2026\-05\-15" "r42" "DOCUMENTATION" .TH "LF" "1" "2026\-05\-30" "r42" "DOCUMENTATION"
.SH NAME .SH NAME
lf \- terminal file manager lf \- terminal file manager
.SH SYNOPSIS .SH SYNOPSIS
@@ -67,7 +67,7 @@ This only affects which \f[CR]lfrc\f[R] is read at startup.
.TP .TP
\f[B]\-print\-last\-dir\f[R] \f[B]\-print\-last\-dir\f[R]
Print the last directory to stdout when lf exits. Print the last directory to stdout when lf exits.
This can be used to let lf change your shells working directory. This can be used to let lf change your shell\(aqs working directory.
See \f[CR]CHANGING DIRECTORY\f[R] for more details. See \f[CR]CHANGING DIRECTORY\f[R] for more details.
.TP .TP
\f[B]\-last\-dir\-path\f[R] \f[I]path\f[R] \f[B]\-last\-dir\-path\f[R] \f[I]path\f[R]
@@ -1025,8 +1025,8 @@ List of attributes that are preserved when copying files.
Currently supported attributes are \f[CR]mode\f[R] (i.e. Currently supported attributes are \f[CR]mode\f[R] (i.e.
access mode) and \f[CR]timestamps\f[R] (i.e. access mode) and \f[CR]timestamps\f[R] (i.e.
modification time and access time). modification time and access time).
Note that preserving other attributes like ownership of change/birth Note that preserving other attributes like ownership or change/birth
timestamp is desirable, but not portably supported in Go. timestamps is desirable, but not portably supported in Go.
.SS preview (bool) (default true) .SS preview (bool) (default true)
Show previews of files and directories at the rightmost pane. Show previews of files and directories at the rightmost pane.
If the file has more lines than the preview pane, the rest of the lines If the file has more lines than the preview pane, the rest of the lines
@@ -2186,9 +2186,9 @@ user navigates through them.
In this case, if the exit code of the preview script is zero, then the In this case, if the exit code of the preview script is zero, then the
output will be cached in memory and displayed by lf (useful for text or output will be cached in memory and displayed by lf (useful for text or
sixel previews). sixel previews).
Otherwise, it will fallback to calling the preview script again when the Otherwise, it will fall back to calling the preview script again when
file is actually selected (useful for previews managed by an external the file is actually selected (useful for previews managed by an
program). external program).
.SH CHANGING DIRECTORY .SH CHANGING DIRECTORY
lf changes the working directory of the process to the current directory lf changes the working directory of the process to the current directory
so that shell commands always work in the displayed directory. so that shell commands always work in the displayed directory.
@@ -2239,9 +2239,9 @@ cmd on\-cd &{{ ... }}
on\-cd on\-cd
.EE .EE
.PP .PP
Note that all shell commands are possible but \f[CR]%\f[R] and Note that all shell command types can be used, but \f[CR]%\f[R] and
\f[CR]&\f[R] are usually more appropriate as \f[CR]$\f[R] and \f[CR]&\f[R] are usually more appropriate, as \f[CR]$\f[R] and
\f[CR]!\f[R] causes flickers and pauses respectively. \f[CR]!\f[R] cause flickering and pauses respectively.
.PP .PP
There is also a \f[CR]pre\-cd\f[R] command, that works like There is also a \f[CR]pre\-cd\f[R] command, that works like
\f[CR]on\-cd\f[R], but is run before the directory is actually changed. \f[CR]on\-cd\f[R], but is run before the directory is actually changed.
@@ -2362,7 +2362,7 @@ escapes.
See the default value of this option to have an idea about how to color See the default value of this option to have an idea about how to color
this line. this line.
.PP .PP
It is worth noting that lf uses as many colors advertised by your It is worth noting that lf uses as many colors as advertised by your
terminal\(aqs entry in terminfo or infocmp databases on your system. terminal\(aqs entry in terminfo or infocmp databases on your system.
If an entry is not present, it falls back to an internal database. If an entry is not present, it falls back to an internal database.
If your terminal supports 24\-bit colors but either does not have a If your terminal supports 24\-bit colors but either does not have a
@@ -2524,7 +2524,7 @@ The variable uses the same syntax as \f[CR]LS_COLORS/LF_COLORS\f[R].
Instead of colors, you should use single characters or symbols as Instead of colors, you should use single characters or symbols as
values. values.
The \f[CR]ln\f[R] entry supports the special value \f[CR]target\f[R], The \f[CR]ln\f[R] entry supports the special value \f[CR]target\f[R],
which will use the link target to select a icon. which will use the link target to select an icon.
Filename rules will still apply based on the link\(aqs name \-\- this Filename rules will still apply based on the link\(aqs name \-\- this
mirrors GNU\(aqs \f[CR]ls\f[R] and \f[CR]dircolors\f[R] behavior. mirrors GNU\(aqs \f[CR]ls\f[R] and \f[CR]dircolors\f[R] behavior.
The icons file (refer to the \c The icons file (refer to the \c