diff --git a/CHANGELOG.md b/CHANGELOG.md index 9a9f44e..669f460 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Increase build speed of root configuration by only importing required Composites/Resources. - Added ''UseEnvironment'' parameter to cater for RSOP for identical node names in different environments. - Adding Home.md to wikiSource and correct casing. +- Removed PSModulePath manipulation from task `CompileRootConfiguration.build.ps1`. This is now handled by the Sampler task `Set_PSModulePath`. +- Redesign of the function Split-Array. Most of the time it was not working as expected, especially when requesting larger ChunkCounts (see AutomatedLab/AutomatedLab.Common/#118) - Redesign of the function Split-Array. Most of the time it was not working as expected, especially when requesting larger ChunkCounts (see AutomatedLab/AutomatedLab.Common/#118). - Improved error handling when compiling MOF files and when calling 'Get-DscResource'. - Redesign of the function 'Split-Array'. Most of the time it was not working as expected, especially when requesting larger ChunkCounts (see AutomatedLab/AutomatedLab.Common/#118). diff --git a/source/Tasks/CompileRootConfiguration.build.ps1 b/source/Tasks/CompileRootConfiguration.build.ps1 index 4f2d2f2..2d4eb47 100644 --- a/source/Tasks/CompileRootConfiguration.build.ps1 +++ b/source/Tasks/CompileRootConfiguration.build.ps1 @@ -60,13 +60,6 @@ task CompileRootConfiguration { Start-Transcript -Path "$BuildOutput\Logs\CompileRootConfiguration.log" try { - $originalPSModulePath = $env:PSModulePath - $env:PSModulePath = ($env:PSModulePath -split [System.IO.Path]::PathSeparator).Where({ - $_ -notmatch ([regex]::Escape('powershell\7\Modules')) -and - $_ -notmatch ([regex]::Escape('Program Files\WindowsPowerShell\Modules')) -and - $_ -notmatch ([regex]::Escape('Documents\PowerShell\Modules')) - }) -join [System.IO.Path]::PathSeparator - Write-Build Green '' if ((Test-Path -Path (Join-Path -Path $SourcePath -ChildPath RootConfiguration.ps1)) -and (Test-Path -Path (Join-Path -Path $SourcePath -ChildPath CompileRootConfiguration.ps1))) @@ -105,7 +98,6 @@ task CompileRootConfiguration { } finally { - $env:PSModulePath = $originalPSModulePath Stop-Transcript }