New-Log¶
SYNOPSIS¶
Creates a new log object with specified parameters.
SYNTAX¶
New-Log [[-ScriptPath] <String>] [[-Dir] <String>] [[-Name] <String>] [[-OutHost] <Boolean>]
DESCRIPTION¶
{{ Fill in the Description }}
EXAMPLES¶
Example 1¶
PS C:\> {{ Add example code here }}
{{ Add example description here }}
PARAMETERS¶
-ScriptPath¶
The path to the script for which the log is being created. Used to derive default log directory and name if not provided.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Dir¶
The directory where the log files will be stored. If not provided, a default directory is derived.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Name¶
The base name of the log file. If not provided, it is derived from the script name.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-OutHost¶
A boolean indicating whether log messages should also be output to the host.
Type: Boolean
Parameter Sets: (All)
Aliases:
Required: False
Position: 4
Default value: False
Accept pipeline input: False
Accept wildcard characters: False