New-PSConfigFile
SYNOPSIS
Creates a new config file
SYNTAX
New-PSConfigFile [-ConfigDir] <DirectoryInfo> [[-BackupsToKeep] <Int32>] [-WhatIf] [-Confirm]
[<CommonParameters>]
DESCRIPTION
Creates a new config file. If a config file already exists in that folder, it will be renamed.
EXAMPLES
EXAMPLE 1
New-PSConfigFile -ConfigDir C:\Temp\config -BackupsToKeep 3
PARAMETERS
-ConfigDir
Directory to create config file
Type: DirectoryInfo
Parameter Sets: (All)
Aliases:
Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-BackupsToKeep
The amount of copies to keep of the config file when config is changed.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: 10
Accept pipeline input: False
Accept wildcard characters: False
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.