Combines a filename with a string.
Join-FileName.ps1 [-Path] <String> [-AppendText] <String> [-ProgressAction <ActionPreference>]
[<CommonParameters>]
Join-FileName appends a string to a filename, including a new extension overwrites the filename’s extension.
Join-FileName.ps1 activity.log '-20161111'
activity-20161111.log
Join-FileName.ps1 readme.txt .bak
readme.bak
Join-FileName.ps1 C:\temp\activity.log .27.old
C:\temp\activity.27.old
The path to a file.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False
Text to append to the filename, either before the extension or including one.
Type: String
Parameter Sets: (All)
Aliases: Extension
Required: True
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Type: ActionPreference
Parameter Sets: (All)
Aliases: proga
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.