id = "kakoune"
name = "Kakoune"
homepage = "https://github.com/mawww/kakoune"
description = "A code editor for the terminal."
executables = ["kak"]
[dotfiles]
paths = ["[configHome]/kak/kakrc", "[configHome]/kak/autoload/"]
secret = []
[commands]
format = 1
label = "Open files in Kakoune"
description = "Start an editor session on files, optionally named, read-only or connected to an existing session. Filter mode, JSON UI and session piping are left out."
quality = "ai-draft"
parser = { end_of_options = "--", interleave = "permute", long_equals = false, short_attached = false, short_bundles = false }
[[commands.source]]
id = "man"
kind = "manual"
url = "https://github.com/mawww/kakoune/blob/master/doc/kak.1"
revision = "master 2026-10-27"
evidence = """
SYNOPSIS (rendered): kak [-d] [-n] [-ro] [-c session_id | -C session_id | -s session_id] [-ui ui_type] [-e command] [-E command] [file ...]; kak -l
.It Fl n
Do not load the system's kakrc.
.It Fl l
List existing sessions.
.It Fl d
Run as a headless session
.It Fl e Ar command
Execute
.It Fl c Ar session_id
Connect to the given session
.It Fl C Ar session_id
or create it if it does not exist.
.It Fl s Ar session_id
Set the current session name to
.It Fl ro
Begin in
.Em readonly mode ,
.It Ar file ...
One or more
"""
[[commands.field]]
id = "session"
label = "Session name"
type = "string"
option = ["-s"]
sources = ["man"]
[[commands.field]]
id = "connect"
label = "Connect to session"
type = "string"
option = ["-c"]
sources = ["man"]
[[commands.field]]
id = "connect_or_create"
label = "Connect to or create session"
type = "string"
option = ["-C"]
sources = ["man"]
[[commands.field]]
id = "readonly"
label = "Read-only"
type = "boolean"
option = ["-ro"]
sources = ["man"]
[[commands.field]]
id = "no_rc"
label = "Skip system kakrc"
type = "boolean"
option = ["-n"]
sources = ["man"]
[[commands.field]]
id = "command"
label = "Run command after client init"
type = "string"
option = ["-e"]
sources = ["man"]
[[commands.field]]
id = "list"
label = "List sessions"
type = "boolean"
option = ["-l"]
sources = ["man"]
[[commands.field]]
id = "files"
label = "Files"
type = "path"
position = 0
multiple = true
path = { kind = "file", role = "input" }
sources = ["man"]
[[commands.task]]
id = "edit"
label = "Edit files"
fields = ["files", "session", "readonly", "command"]
required = []
[[commands.task]]
id = "view"
label = "View read-only"
set = { readonly = [true] }
lock = ["readonly"]
fields = ["files", "readonly", "no_rc"]
required = ["files"]
[[commands.task]]
id = "sessions"
label = "List sessions"
set = { list = [true] }
lock = ["list"]
fields = ["list"]
required = []
[[commands.group]]
id = "basic"
label = "Basic"
fields = ["files", "readonly", "session", "connect"]
[[commands.group]]
id = "advanced"
label = "Advanced"
fields = ["connect_or_create", "no_rc", "command", "list"]