Skip to content
ConsoleMonster
Cmdlet

Show-ConsoleHelp

Module ConsoleMonster
Inputs
System.String
Outputs
System.String

Shows a command's help: synopsis, highlighted syntax, a parameter table and highlighted examples.

Syntax

Show-ConsoleHelp [-AsString] [-Name] <String> [-NoExamples] [-Width <Int32>] [<CommonParameters>]
#
Parameter set: All Parameter Sets

Description

Shows a command's help: synopsis, highlighted syntax, a parameter table and highlighted examples.

Reads the help PowerShell has for the command (Get-Help -Full): cmdlet help files, comment-based help of functions and scripts, or the help PowerShell generates when there is none. It shows the name and synopsis, the syntax of each parameter set (parameter names, value types and optional parts told apart), the description, a parameter table (type, required, position, pipeline input, default, description), the examples with highlighted PowerShell code, inputs, outputs, notes and related links. Piped on (| more, | Out-Host -Paging, | Out-File) it writes plain lines, so pagers and files get readable text. About topics are written as they are. Works on Windows PowerShell 5.1 and PowerShell 7.

Examples

Authored help example

EXAMPLE 1

Show-ConsoleHelp Get-ChildItem

A cmdlet

EXAMPLE 2

Show-ConsoleHelp Format-ConsoleTable | more

Through a pager

Parameters

-AsString SwitchParameter optional
Returns the help as one string of plain text instead of drawing it.
-Name String requiredposition: 0pipeline: True (ByPropertyName)
The command (a cmdlet, function, alias or script path), or an about topic.
-NoExamples SwitchParameter optional
Leaves out the examples.
-Width Int32 optional
The width in columns (default: the console's width).

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.