Skip to content

Commit

Permalink
!deploy v0.1.8
Browse files Browse the repository at this point in the history
## 0.1.8 - 2019-08-26

* Fixed issue with `$PSProfile.ModulesToImport` where an empty string was added to the array, resulting in a Warning during profile load about the module failing to import.
  • Loading branch information
scrthq committed Aug 26, 2019
1 parent 46b95c9 commit 014d422
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
* [PSProfile - ChangeLog](#psprofile---changelog)
* [0.1.8 - 2019-08-26](#018---2019-08-26)
* [0.1.7 - 2019-08-25](#017---2019-08-25)
* [0.1.6 - 2019-08-24](#016---2019-08-24)
* [0.1.5 - 2019-08-22](#015---2019-08-22)
Expand All @@ -12,6 +13,10 @@

# PSProfile - ChangeLog

## 0.1.8 - 2019-08-26

* Fixed issue with `$PSProfile.ModulesToImport` where an empty string was added to the array, resulting in a Warning during profile load about the module failing to import.

## 0.1.7 - 2019-08-25

* Fixed `Task` parameter type on `Start-BuildScript` to allow an array of strings.
Expand Down
10 changes: 5 additions & 5 deletions PSProfile/Classes/PSProfile.Classes.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -314,16 +314,16 @@ class PSProfile {
"Debug"
)
$final = @{ }
$Global:PSProfile.Prompts.GetEnumerator() | ForEach-Object {
$this.Prompts.GetEnumerator() | ForEach-Object {
$this._log(
"Formatting prompt '$($_.Key)' via Trim()",
"Formatting prompt '$($_.Key)'",
"FormatPrompts",
"Verbose"
)
$updated = ($_.Value -split "[\r\n]" | Where-Object { $_ }).Trim() -join "`n"
$final[$_.Key] = $updated
}
$Global:PSProfile.Prompts = $final
$this.Prompts = $final
$this._log(
"SECTION END",
"FormatPrompts",
Expand Down Expand Up @@ -642,7 +642,7 @@ class PSProfile {
'Debug'
)
if (-not [string]::IsNullOrEmpty((-join $this.ModulesToInstall))) {
$null = $this.ModulesToInstall | Start-RSJob -Name { "_PSProfile_InstallModule_$($_)" } -VariablesToImport this -ScriptBlock {
$null = $this.ModulesToInstall | Where-Object {-not [string]::IsNullOrEmpty($_)} | Start-RSJob -Name { "_PSProfile_InstallModule_$($_)" } -VariablesToImport this -ScriptBlock {
Param (
[parameter()]
[object]
Expand Down Expand Up @@ -699,7 +699,7 @@ class PSProfile {
'Debug'
)
if (-not [string]::IsNullOrEmpty((-join $this.ModulesToImport))) {
$this.ModulesToImport | ForEach-Object {
$this.ModulesToImport | Where-Object {-not [string]::IsNullOrEmpty($_)} | ForEach-Object {
try {
$params = if ($_ -is [string]) {
@{Name = $_ }
Expand Down

0 comments on commit 014d422

Please sign in to comment.