Add file completions for cleaner and previewer (#2211)

This commit is contained in:
CatsDeservePets authored and GitHub committed 2025-10-19 04:18:01 +02:00
1 parent 06376f9089
commit 8a8f8180af
2 files changed
+3 -1

No files matched your search

+1 -1
View File
@@ -28,7 +28,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
- Natural sorting now compares string lengths when dealing with equivalent numbers (e.g. `0` is ordered before `00`) (#2177).
- A bug where the copy progress indicator only displayed the first time a file was copied is now fixed (#2181).
- A bug where the `source` command does not show an error message upon failure is now fixed (#2189).
- The `addcustominfo` command now supports file completions (#2198).
- The `addcustominfo` command as well as the `cleaner` and `previewer` options now support file completions (#2198) (#2211).
- A bug where an empty `custom` info property would still take up space is now fixed (#2208).
## [r38](https://github.com/gokcehan/lf/releases/tag/r38)
+2
View File
@@ -403,6 +403,8 @@ func completeCmd(acc []rune) (matches []compMatch, result string) {
matches, result = matchWord(f[2], []string{"binary", "decimal"})
case "sortby":
matches, result = matchWord(f[2], []string{"atime", "btime", "ctime", "custom", "ext", "name", "natural", "size", "time"})
case "cleaner", "previewer":
matches, result = matchCmdFile(f[2], false)
default:
if slices.Contains(gOptWords, f[1]+"!") {
matches, result = matchWord(f[2], []string{"false", "true"})