feat!: Load ruler file dynamically (#2338)
* feat!: Load ruler file dynamically * Add documentation * Fix bug with custom filename * Update `CHANGELOG.md` * Add docs for `statfmt`
This commit is contained in:
1 parent
d00fd5c752
commit
8ed089cc25
11 files changed
+61
-81
No files matched your search
@@ -1,6 +1,6 @@
|
||||
.\" Automatically generated by Pandoc 3.7.0.2
|
||||
.\"
|
||||
.TH "LF" "1" "2026\-01\-11" "r41" "DOCUMENTATION"
|
||||
.TH "LF" "1" "2026\-01\-12" "r41" "DOCUMENTATION"
|
||||
.SH NAME
|
||||
lf \- terminal file manager
|
||||
.SH SYNOPSIS
|
||||
@@ -325,8 +325,8 @@ ratios []int (default \(aq1:2:3\(aq)
|
||||
relativenumber bool (default false)
|
||||
reverse bool (default false)
|
||||
roundbox bool (default false)
|
||||
rulerfile bool (default false)
|
||||
rulerfmt string (default \(dq %a| %p| \(rs033[7;31m %m \(rs033[0m| \(rs033[7;33m %c \(rs033[0m| \(rs033[7;35m %s \(rs033[0m| \(rs033[7;36m %v \(rs033[0m| \(rs033[7;34m %f \(rs033[0m| %i/%t\(dq)
|
||||
rulerfile string (default \(dq\(dq)
|
||||
rulerfmt string (default \(dq\(dq)
|
||||
scrolloff int (default 0)
|
||||
searchmethod string (default \(aqtext\(aq)
|
||||
selectfmt string (default \(dq\(rs033[7;35m\(dq)
|
||||
@@ -492,14 +492,6 @@ Unix /etc/lf/icons \(ti/.config/lf/icons
|
||||
Windows C:\(rsProgramData\(rslf\(rsicons C:\(rsUsers\(rs<user>\(rsAppData\(rsRoaming\(rslf\(rsicons
|
||||
.EE
|
||||
.PP
|
||||
The ruler file should be located at:
|
||||
.IP
|
||||
.EX
|
||||
OS system\-wide user\-specific
|
||||
Unix /etc/lf/ruler \(ti/.config/lf/ruler
|
||||
Windows C:\(rsProgramData\(rslf\(rsruler C:\(rsUsers\(rs<user>\(rsAppData\(rsRoaming\(rslf\(rsruler
|
||||
.EE
|
||||
.PP
|
||||
The selection file should be located at:
|
||||
.IP
|
||||
.EX
|
||||
@@ -1068,16 +1060,20 @@ Reverse the direction of sort.
|
||||
.SS roundbox (bool) (default false)
|
||||
Draw rounded outer corners when the \f[CR]drawbox\f[R] option is
|
||||
enabled.
|
||||
.SS rulerfile (bool) (default false)
|
||||
Use the ruler file instead of the \f[CR]rulerfmt\f[R] and
|
||||
\f[CR]statfmt\f[R] options when drawing the ruler at the bottom.
|
||||
.SS rulerfile (string) (default \(ga\(ga)
|
||||
Set the path of the ruler file.
|
||||
If not set, then a default template will be used for the ruler.
|
||||
Refer to the \c
|
||||
.UR https://github.com/gokcehan/lf/blob/master/doc.md#ruler
|
||||
RULER section
|
||||
.UE \c
|
||||
\ for more information about how the ruler file works.
|
||||
.SS rulerfmt (string) (default \f[CR] %a| %p| \(rs033[7;31m %m \(rs033[0m| \(rs033[7;33m %c \(rs033[0m| \(rs033[7;35m %s \(rs033[0m| \(rs033[7;36m %v \(rs033[0m| \(rs033[7;34m %f \(rs033[0m| %i/%t\f[R])
|
||||
.SS rulerfmt (string) (default \(ga\(ga)
|
||||
Format string of the ruler shown in the bottom right corner.
|
||||
When set, it will be used along with \f[CR]statfmt\f[R] to draw the
|
||||
ruler, and \f[CR]rulerfile\f[R] will be ignored.
|
||||
However, using \f[CR]rulerfile\f[R] is preferred and this option is
|
||||
provided for backwards compatibility.
|
||||
.PP
|
||||
The following special expansions are supported:
|
||||
.IP
|
||||
@@ -1168,6 +1164,9 @@ custom property defined via \(gaaddcustominfo\(ga (empty by default)
|
||||
.EE
|
||||
.SS statfmt (string) (default \f[CR]\(rs033[36m%p\(rs033[0m| %c| %u| %g| %S| %t| \-> %l\f[R])
|
||||
Format string of the file info shown in the bottom left corner.
|
||||
This option has no effect unless \f[CR]rulerfmt\f[R] is also set.
|
||||
Using \f[CR]rulerfile\f[R] is preferred and this option is provided for
|
||||
backwards compatibility.
|
||||
.PP
|
||||
The following special expansions are supported:
|
||||
.IP
|
||||
@@ -2514,7 +2513,8 @@ A sample colored icons file can be found at \c
|
||||
.UR https://github.com/gokcehan/lf/blob/master/etc/icons_colored.example
|
||||
.UE \c
|
||||
.SH RULER
|
||||
The ruler can be configured using a ruler file (refer to the \c
|
||||
The ruler can be configured using the \f[CR]rulerfile\f[R] option (refer
|
||||
to the \c
|
||||
.UR https://github.com/gokcehan/lf/blob/master/doc.md#configuration
|
||||
CONFIGURATION section
|
||||
.UE \c
|
||||
@@ -2524,8 +2524,6 @@ rendered to create the actual output (refer to \c
|
||||
.UR https://pkg.go.dev/text/template
|
||||
.UE \c
|
||||
\ for more details on the syntax).
|
||||
This feature is currently experimental and must be enabled via the
|
||||
\f[CR]rulerfile\f[R] option.
|
||||
.PP
|
||||
The following data fields are exported:
|
||||
.IP
|
||||
|
||||
Reference in new issue
Block a user