From 19cf8fe1574a3f9e2e773ef313c41bf9ca07fb0f Mon Sep 17 00:00:00 2001 From: srdusr Date: Thu, 30 May 2024 03:20:13 +0200 Subject: Testing --- .config/powershell/bootstrap.ps1 | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to '.config') diff --git a/.config/powershell/bootstrap.ps1 b/.config/powershell/bootstrap.ps1 index cf8f9a5..c655986 100644 --- a/.config/powershell/bootstrap.ps1 +++ b/.config/powershell/bootstrap.ps1 @@ -294,16 +294,16 @@ New-Item -ItemType HardLink -Force ` -Path "$powerShellProfileDir\Microsoft.PowerShell_profile.ps1" ` -Target "$home\.config\powershell\Microsoft.PowerShell_profile.ps1" -## Set environment variable -#[System.Environment]::SetEnvironmentVariable('PowerShellProfileDir', $powerShellProfileDir, [System.EnvironmentVariableTarget]::User) -# -#Write-Host "PowerShell profile directory set to: $powerShellProfileDir" -#Write-Host "Environment variable 'PowerShellProfileDir' set to: $powerShellProfileDir" +# Set environment variable +[System.Environment]::SetEnvironmentVariable('PowerShellProfileDir', $powerShellProfileDir, [System.EnvironmentVariableTarget]::User) -## Verify profile sourcing -#if (!(Test-Path -Path "$home\.config\powershell\Microsoft.PowerShell_profile.ps1")) { -# handle_error "PowerShell profile does not exist. Please create it at $home\.config\powershell\Microsoft.PowerShell_profile.ps1" -#} +Write-Host "PowerShell profile directory set to: $powerShellProfileDir" +Write-Host "Environment variable 'PowerShellProfileDir' set to: $powerShellProfileDir" + +# Verify profile sourcing +if (!(Test-Path -Path "$home\.config\powershell\Microsoft.PowerShell_profile.ps1")) { + handle_error "PowerShell profile does not exist. Please create it at $home\.config\powershell\Microsoft.PowerShell_profile.ps1" +} # Define the `config` alias in the current session function global:config { -- cgit v1.2.3