feat: am tip cheat sheet + readable man pages + REPL completion refresh

This commit is contained in:
2026-08-17 21:50:48 -04:00
parent 53893f2967
commit 98c0b30f68
10 changed files with 1402 additions and 63 deletions
+25 -4
View File
@@ -885,8 +885,8 @@ pub static HELP_SPECS: &[HelpSpec] = &[
name: "man",
category: "Commands",
usage: "man {flags} [command]",
about: "Generate roff man pages from the command definitions: one page for the whole CLI, or one page per command with --output.",
search_terms: &["documentation", "roff", "unix"],
about: "Readable man pages in the terminal (the raw roff source is kept when piped): one page for the whole CLI, or one per command with --output.",
search_terms: &["documentation", "roff", "unix", "manual"],
flags: &[
HelpFlag { short: "", long: "--output", value: "DIR", desc: "Write am.1 plus one am-<command>.1 per command into this directory" },
],
@@ -896,9 +896,10 @@ pub static HELP_SPECS: &[HelpSpec] = &[
],
io: None,
examples: &[
HelpExample { desc: "Print the man page of the whole CLI.", code: "man" },
HelpExample { desc: "Print one command page.", code: "man install" },
HelpExample { desc: "Read the man page of the whole CLI (rendered in the terminal).", code: "man" },
HelpExample { desc: "Read one command page.", code: "man install" },
HelpExample { desc: "Write every page into man/ (for a package).", code: "man --output man/" },
HelpExample { desc: "Pipe the raw roff source into a real man viewer.", code: "man | man -l -" },
],
},
HelpSpec {
@@ -953,6 +954,26 @@ pub static HELP_SPECS: &[HelpSpec] = &[
HelpExample { desc: "Switch to the ocean theme (kept for the next start).", code: "theme ocean" },
],
},
HelpSpec {
name: "tip",
category: "Commands",
usage: "tip {flags}",
about: "Cheat sheet : les commandes les plus utiles avec leurs options clés, vos commandes les plus utilisées et une astuce du jour.",
search_terms: &["cheat", "sheet", "tips", "astuce", "aide", "raccourci", "usage"],
flags: &[HelpFlag {
short: "",
long: "--random",
value: "",
desc: "Show a single random tip instead of the whole page",
}],
subcommands: &[],
parameters: &[],
io: None,
examples: &[
HelpExample { desc: "Show the whole cheat sheet.", code: "tip" },
HelpExample { desc: "Show a single random tip.", code: "tip --random" },
],
},
HelpSpec {
name: "ls",
category: "Shell",