-
-
Notifications
You must be signed in to change notification settings - Fork 495
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
28 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Ensure the script is executed in the root of the Harmony project | ||
if (-not (Test-Path .git) -or -not (Test-Path Harmony.sln)) { | ||
Write-Host "This script must be run from the root of the Harmony project." | ||
exit | ||
} | ||
|
||
# Clear out old pack results from Harmony\bin and clean the project once for all configurations | ||
Write-Host "Cleaning Harmony\bin directory and project..." | ||
if (Test-Path Harmony\bin) { | ||
Remove-Item Harmony\bin -Recurse | ||
} | ||
New-Item -ItemType Directory -Path Harmony\bin | Out-Null | ||
|
||
# Clean the project | ||
dotnet clean --nologo --verbosity minimal | ||
|
||
# Define configurations | ||
$configurations = @('ReleaseFat', 'ReleaseThin', 'DebugFat', 'DebugThin') | ||
|
||
# Loop through each configuration for building and packing | ||
foreach ($config in $configurations) { | ||
Write-Host "Processing configuration: $config" | ||
# Building the project for the specific configuration | ||
dotnet build --nologo --configuration $config --verbosity minimal | ||
dotnet pack --nologo --configuration $config --verbosity minimal | ||
} |