From c7b681a2b55d0c248acf0289f7502534624bbde2 Mon Sep 17 00:00:00 2001 From: Jan De Dobbeleer Date: Thu, 31 Mar 2022 07:18:02 +0200 Subject: [PATCH] fix(pwsh): trim trailing backslash from paths relates to #2009 --- src/shell/scripts/omp.ps1 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/shell/scripts/omp.ps1 b/src/shell/scripts/omp.ps1 index 70e6cb90..a9c4125a 100644 --- a/src/shell/scripts/omp.ps1 +++ b/src/shell/scripts/omp.ps1 @@ -51,6 +51,8 @@ function global:Set-PoshContext {} function global:Get-PoshContext { $cleanPWD = $PWD.ProviderPath $cleanPSWD = $PWD.ToString() + $cleanPWD = $cleanPWD.TrimEnd('\') + $cleanPSWD = $cleanPSWD.TrimEnd('\') return $cleanPWD, $cleanPSWD }