| external help file | PSDocs-help.xml |
|---|---|
| Module Name | PSDocs |
| online version | https://github.com/Microsoft/PSDocs/blob/main/docs/commands/PSDocs/en-US/New-PSDocumentOption.md |
| schema | 2.0.0 |
Create options to configure document generation.
New-PSDocumentOption [-Path <String>] [-Format <InputFormat>] [-InputObjectPath <String>]
[-InputPathIgnore <String[]>] [-Encoding <MarkdownEncoding>] [-Culture <String[]>] [-OutputPath <String>]
[<CommonParameters>]
New-PSDocumentOption -Option <PSDocumentOption> [-Format <InputFormat>] [-InputObjectPath <String>]
[-InputPathIgnore <String[]>] [-Encoding <MarkdownEncoding>] [-Culture <String[]>] [-OutputPath <String>]
[<CommonParameters>]
New-PSDocumentOption [-Default] [-Format <InputFormat>] [-InputObjectPath <String>]
[-InputPathIgnore <String[]>] [-Encoding <MarkdownEncoding>] [-Culture <String[]>] [-OutputPath <String>]
[<CommonParameters>]
The New-PSDocumentOption cmdlet creates an options object that can be passed to PSDocs cmdlets to configure document generation behaviour.
PS C:\> $option = New-PSDocumentOption -Option @{ 'Markdown.WrapSeparator' = '<br />' };
PS C:\> Invoke-PSDocument -Name 'Sample' -Option $option;Create markdown using the Sample documentation definition using a wrap separator of <br />.
Additional options that configure document generation. Option also accepts a hashtable to configure options.
Type: PSDocumentOption
Parameter Sets: FromOption
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe path to a YAML file containing options.
Type: String
Parameter Sets: FromPath
Aliases:
Required: False
Position: Named
Default value: .\ps-docs.yaml
Accept pipeline input: False
Accept wildcard characters: FalseWhen specified, defaults are used for any options not overridden.
Type: SwitchParameter
Parameter Sets: FromDefault
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseSets the Input.Format option to configure the input format for when a string is passed in as a target object.
See about_PSDocs_Options for more information.
Type: InputFormat
Parameter Sets: (All)
Aliases: InputFormat
Accepted values: None, Yaml, Json, PowerShellData, Detect
Required: False
Position: Named
Default value: Detect
Accept pipeline input: False
Accept wildcard characters: FalseSets the Input.ObjectPath option to use an object path to use instead of the pipeline object.
See about_PSDocs_Options for more information.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseSets the Input.PathIgnore option.
If specified, files that match the path spec will not be processed.
See about_PSDocs_Options for more information.
Type: String[]
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseSets the option Markdown.Encoding.
Specifies the file encoding for generated markdown files.
By default, UTF-8 without byte order mark (BOM) will be used.
See about_PSDocs_Options for more information.
Type: MarkdownEncoding
Parameter Sets: (All)
Aliases: MarkdownEncoding
Accepted values: Default, UTF8, UTF7, Unicode, UTF32, ASCII
Required: False
Position: Named
Default value: Default
Accept pipeline input: False
Accept wildcard characters: FalseSets the option Output.Culture.
Specifies a list of cultures for building documents such as en-AU, and en-US.
See about_PSDocs_Options for more information.
Type: String[]
Parameter Sets: (All)
Aliases: OutputCulture
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseSets the option Output.Path.
The option specified one or more custom field bindings.
See about_PSDocs_Options for more information.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.