From b32e93de75b919a1c009ec03548b7d0b7034ac8c Mon Sep 17 00:00:00 2001 From: Bruce Weirdan Date: Sun, 27 Apr 2025 23:36:20 +0200 Subject: [PATCH] Clarify `Extension` section purpose --- crates/nu-std/std/help/mod.nu | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/nu-std/std/help/mod.nu b/crates/nu-std/std/help/mod.nu index cc7343ae33..6b754c96c9 100644 --- a/crates/nu-std/std/help/mod.nu +++ b/crates/nu-std/std/help/mod.nu @@ -492,7 +492,6 @@ def get-extension-by-prefix [prefix: string] { | rename --column { name: command } } - def get-command-extensions [command: string] { # low-tech version of `nu-highlight`, which produces suboptimal results with unknown commands def hl [shape: string] { @@ -710,6 +709,8 @@ def build-command-page [command: record] { ] | flatten) } else { [] }) + # This section documents how the command can be extended + # E.g. `open` can be extended by adding more `from ...` commands let extensions = ( get-command-extensions $command.name | if ($in | is-not-empty) {