* Add `fileinfofmt` option
* echof is now unused
* Use different default for Windows
* Add new line to docs
* Indent placeholders description in documentation
* Change option name to `statfmt`
* Use plain text format for documentation
This is a natural complement to the recently introduces `maps` and `cmaps`.
I considered using a different output format, since `cmd` definitions can be
long, but I decided against it for now. `lf` already abbreviates commands that
take up several lines, and we can change the output format later if needed.
* Add support for displaying lf options in the ruler
* Print escape character as plain text
* Document user defined options
* Change escape rules
* Use reflect instead of environment table
* Factor out common option map logic
* Improve error message slightly
* Display blank option values
* make it possible to preserve mtime and atime when copying files
Preserving other attributes like ownership, ctime or btime of a file is
desired but currently not possible to implement in a portable way with go.
Fixes#869
Relates to #779
* FIXUP use cp-compatible default for not-preserving mode
* Refactor piping to pager: extract to separate function, simplify invocation
This is meant to be straightforward and clearly a no-op,\
at the cost of being a bit verbose.
* Refactor: reduce duplication between sync shell commands and pager
* Refactor: minor cleanup of async shell functions
After the previous refactors, the logic for async shell commands can
be simplified somewhat. There is likely room for further improvements,
but that is beyond the scope of this PR.
* Remove duplicated shellSetPG invocation
See https://github.com/gokcehan/lf/pull/1243#discussion_r1193078282
* Support modifiers in mappings
* Update docs
* Support cmap keybindings as well
* Implement push
* Move order of escape key check
* Add safety check
* Fix safety check
* Factor out common logic
* Make `:maps` work on Windows
This makes the `:maps` command from #1146 work on Windows.
This (as well as `:maps` itself) is based on @jackielli's work in #1146 and
#1152.
I intend to refactor the code in this or a separate PR, but I thought I'd
submit the critical and simple bit first.
* Add `:cmaps` command
After the naming scheme from #1146, it would seem weird to not have a :cmaps
command. This could help with issues like #876.