From 5e229d12282ea8c3f2062b59a3e17d2cf77cc426 Mon Sep 17 00:00:00 2001 From: Enno Date: Wed, 29 Sep 2021 09:32:06 +0200 Subject: [PATCH 1/2] reuse exisiting global $options variable to avoid a clash with other global `$options` variables defined [elsewhere](https://github.com/badmotorfinger/z/blob/a55a57ee05db2abbf7130d7cf350b0b371de5771/z.psm1#L673) --- Set-SolarizedDarkColorDefaults.ps1 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Set-SolarizedDarkColorDefaults.ps1 b/Set-SolarizedDarkColorDefaults.ps1 index 80bd0b3..6ef40b4 100644 --- a/Set-SolarizedDarkColorDefaults.ps1 +++ b/Set-SolarizedDarkColorDefaults.ps1 @@ -14,8 +14,7 @@ $Host.PrivateData.ProgressBackgroundColor = 'Cyan' # Check for PSReadline if (Get-Module -ListAvailable -Name "PSReadline") { - $options = Get-PSReadlineOption - + if (-not $options){ $options = Get-PSReadlineOption } if ([System.Version](Get-Module PSReadline).Version -lt [System.Version]"2.0.0") { # Foreground $options.CommandForegroundColor = 'Yellow' From f11d125cfd8ca63b4281222973102a9deccfdefa Mon Sep 17 00:00:00 2001 From: Enno Date: Wed, 29 Sep 2021 09:33:40 +0200 Subject: [PATCH 2/2] update light variant of powershell profile --- Set-SolarizedLightColorDefaults.ps1 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Set-SolarizedLightColorDefaults.ps1 b/Set-SolarizedLightColorDefaults.ps1 index 1ab47e2..14ff951 100644 --- a/Set-SolarizedLightColorDefaults.ps1 +++ b/Set-SolarizedLightColorDefaults.ps1 @@ -14,8 +14,7 @@ $Host.PrivateData.ProgressBackgroundColor = 'Cyan' # Check for PSReadline if (Get-Module -ListAvailable -Name "PSReadline") { - $options = Get-PSReadlineOption - + if (-not $options){ $options = Get-PSReadlineOption } if ([System.Version](Get-Module PSReadline).Version -lt [System.Version]"2.0.0") { # Foreground $options.CommandForegroundColor = 'Yellow'