"PowerShell Here" does not work if directory contains square brackets

Found this issue when using Directory Opus 12.17 x64 on Windows 10 x64 (19H2, but I also saw this on 19H1 so I don't believe this is related to the Windows version being used)

To replicate:

  • Create a directory that contains square brackets such as C:\[dir]\
  • Navigate to this directory in DO and use PowerShell Here to open a PowerShell
  • The following error is reported in PowerShell:
cd : Cannot find path 'C:\[dir]' because it does not exist.
At line:1 char:1
+ cd "C:\[dir]"
+ ~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (C:\[dir]:String) [Set-Location], ItemNotFoundException
    + FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.SetLocationCommand

If the directory does not contain square brackets, everything is fine. Also, Command Prompt Here cd's to the directory fine even if it has square brackets, it's just PowerShell that doesn't.

Of course, since you can still cd manually to the directory, this is not a major issue. But it would be nice if this could be looked into and hopefully fixed in a future version.

Thanks for the great application!

Thanks! We'll fix that in 12.18.1.