id = "lf"
name = "lf"
homepage = "https://github.com/gokcehan/lf"
description = "A terminal file manager written in Go with a heavy inspiration from ranger file manager."
executables = ["lf"]
[dotfiles]
paths = [
"[configHome]/lf/lfrc",
"[configHome]/lf/colors",
"[configHome]/lf/icons",
]
exclude = [
"~/.local/share/lf/",
"%LOCALAPPDATA%/lf/",
]
secret = []
[commands]
format = 1
label = "Open lf"
description = "Start the lf file manager in a directory, optionally with extra startup commands, a config file, or shell-integration output. Remote control, profiling and server flags are left out."
quality = "ai-draft"
parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = false, short_bundles = false }
[[commands.source]]
id = "doc"
kind = "manual"
url = "https://github.com/gokcehan/lf/blob/master/doc.md"
revision = "2026-10"
evidence = """
**-command** *command*
**-config** *path*
**-last-dir-path** *path*
**-log** *path*
**-print-last-dir**
**-print-selection**
**-selection-path** *path*
**-single**
[*path*]
Execute *command* during client initialization (i.e. after reading configuration, before `on-init`). To execute more than one command, you can either use the **-command** flag multiple times
Use the config file at *path* instead of the normal search locations.
Print the last directory to stdout when lf exits.
Same as **-print-last-dir**, but write the directory to *path* instead of stdout.
Print selected files to stdout when opening a file in lf.
Same as **-print-selection**, but write the newline-separated list to *path* instead of stdout.
Start a stand-alone client without a server. Disables remote control.
Append runtime log messages to *path*.
"""
[[commands.field]]
id = "start_dir"
label = "Start directory"
type = "path"
position = 0
path = { kind = "any", role = "input" }
sources = ["doc"]
[[commands.field]]
id = "command"
label = "Startup command"
description = "lf command run after the config is read; repeat for several."
type = "string"
option = ["-command"]
multiple = true
effect = "exec"
sources = ["doc"]
[[commands.field]]
id = "config"
label = "Config file"
type = "path"
option = ["-config"]
path = { kind = "file", role = "input" }
sources = ["doc"]
[[commands.field]]
id = "print_selection"
label = "Print selection on exit"
type = "boolean"
option = ["-print-selection"]
sources = ["doc"]
[[commands.field]]
id = "selection_path"
label = "Write selection to file"
type = "path"
option = ["-selection-path"]
path = { kind = "file", role = "output", must_exist = false }
effect = "overwrite"
sources = ["doc"]
[[commands.field]]
id = "print_last_dir"
label = "Print last directory on exit"
type = "boolean"
option = ["-print-last-dir"]
sources = ["doc"]
[[commands.field]]
id = "last_dir_path"
label = "Write last directory to file"
type = "path"
option = ["-last-dir-path"]
path = { kind = "file", role = "output", must_exist = false }
effect = "overwrite"
sources = ["doc"]
[[commands.field]]
id = "single"
label = "Stand-alone (no server)"
type = "boolean"
option = ["-single"]
sources = ["doc"]
[[commands.field]]
id = "log"
label = "Log file"
type = "path"
option = ["-log"]
path = { kind = "file", role = "output", must_exist = false }
sources = ["doc"]
[[commands.task]]
id = "browse"
label = "Browse a directory"
fields = ["start_dir"]
[[commands.task]]
id = "pick_files"
label = "Use as a file picker"
fields = ["start_dir", "print_selection", "selection_path"]
required = ["print_selection"]
[[commands.task]]
id = "cd_on_exit"
label = "Record last directory"
fields = ["start_dir", "last_dir_path"]
required = ["last_dir_path"]
[[commands.group]]
id = "basic"
label = "Basic"
fields = ["start_dir", "print_selection", "print_last_dir", "command"]
[[commands.group]]
id = "advanced"
label = "Advanced"
fields = ["config", "selection_path", "last_dir_path", "single", "log"]