Skip to content

Latest commit

 

History

History
43 lines (33 loc) · 650 Bytes

DSCUseVerboseMessageInDSCResource.md

File metadata and controls

43 lines (33 loc) · 650 Bytes
description ms.date ms.topic title
Use verbose message in DSC resource
06/28/2023
reference
DSCUseVerboseMessageInDSCResource

UseVerboseMessageInDSCResource

Severity Level: Information

Description

Best practice recommends that additional user information is provided within commands, functions and scripts using Write-Verbose.

How

Make use of the Write-Verbose command.

Example

Wrong

Function Test-Function
{
    [CmdletBinding()]
    Param()
    ...
}

Correct

Function Test-Function
{
    [CmdletBinding()]
    Param()
    Write-Verbose 'Verbose output'
    ...
}