@@ -31,6 +31,7 @@ function Invoke-RestoreSolution
3131 dotnet restore (Join-Path $PSScriptRoot .\PSScriptAnalyzer.sln)
3232}
3333
34+ Write-Progress " Building ScriptAnalyzer"
3435$solutionDir = Split-Path $MyInvocation.InvocationName
3536if (-not (Test-Path " $solutionDir /global.json" ))
3637{
@@ -63,6 +64,7 @@ if ($Restore.IsPresent)
6364if ($build )
6465{
6566
67+ Write-Progress " Building Engine"
6668 if (-not (Test-DotNetRestore ((Join-Path $solutionDir Engine))))
6769 {
6870 Invoke-RestoreSolution
@@ -76,6 +78,7 @@ if ($build)
7678 {
7779 Invoke-RestoreSolution
7880 }
81+ Write-Progress " Building for framework $Framework , configuration $Configuration "
7982 Push-Location Rules\
8083 dotnet build Rules.csproj -- framework $Framework -- configuration $Configuration
8184 Pop-Location
@@ -84,23 +87,26 @@ if ($build)
8487 {
8588 if (-not (Test-Path $destination ))
8689 {
87- New-Item - ItemType Directory $destination - Force
90+ $null = New-Item - ItemType Directory $destination - Force
8891 }
8992 foreach ($file in $itemsToCopy )
9093 {
91- Copy-Item - Path $file - Destination (Join-Path $destination (Split-Path $file - Leaf)) - Verbose - Force
94+ Copy-Item - Path $file - Destination (Join-Path $destination (Split-Path $file - Leaf)) - Force
9295 }
9396 }
97+
98+
99+ Write-Progress " Copying files to $destinationDir "
94100 CopyToDestinationDir $itemsToCopyCommon $destinationDir
95101 CopyToDestinationDir $itemsToCopyBinaries $destinationDirBinaries
96102
97103 # Copy Settings File
98- Copy-Item - Path " $solutionDir \Engine\Settings" - Destination $destinationDir - Force - Recurse - Verbose
104+ Copy-Item - Path " $solutionDir \Engine\Settings" - Destination $destinationDir - Force - Recurse
99105
100106 # copy newtonsoft dll if net451 framework
101107 if ($Framework -eq " net451" )
102108 {
103- copy-item - path " $solutionDir \Rules\bin\$Configuration \$Framework \Newtonsoft.Json.dll" - Destination $destinationDirBinaries - Verbose
109+ copy-item - path " $solutionDir \Rules\bin\$Configuration \$Framework \Newtonsoft.Json.dll" - Destination $destinationDirBinaries
104110 }
105111}
106112
@@ -112,11 +118,12 @@ if ($uninstall)
112118{
113119 if ((Test-Path $pssaModulePath ))
114120 {
115- Remove-Item - Recurse $pssaModulePath - Verbose
121+ Remove-Item - Recurse $pssaModulePath
116122 }
117123}
118124
119125if ($install )
120126{
121- Copy-Item - Recurse - Path " $destinationDir " - Destination " $modulePath \." - Verbose - Force
122- }
127+ Write-Progress " Installing to $modulePath "
128+ Copy-Item - Recurse - Path " $destinationDir " - Destination " $modulePath \." - Force
129+ }
0 commit comments