You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
566 B
22 lines
566 B
$path = "$PSScriptRoot\..\DiscordChatExporter\bin\Release\*"
|
|
$include = "*.exe", "*.dll", "*.config"
|
|
$outputDir = "$PSScriptRoot\Output"
|
|
$outputFile = "DiscordChatExporter.zip"
|
|
|
|
# Create output directory
|
|
if (-Not (Test-Path $outputDir))
|
|
{
|
|
New-Item $outputDir -ItemType Directory
|
|
}
|
|
|
|
# Delete output if already exists
|
|
if (Test-Path("$outputDir\$outputFile"))
|
|
{
|
|
Remove-Item -Path "$outputDir\$outputFile"
|
|
}
|
|
|
|
# Get files
|
|
$files = Get-ChildItem -Path $path -Include $include
|
|
|
|
# Pack into archive
|
|
$files | Compress-Archive -DestinationPath "$outputDir\$outputFile" |