Issue #190 resolved

Install-Junction fails when the path contains a special char such as [ or ]

Matt Withum
created an issue

First: Thanks for Carbon - it is really amazing!

The Install-Junction.ps1 file checks for existing files by using:

if( -not (Test-Path -Path $Target -PathType Container) )

This will fail when the $Target contains special chars such as []. You can fix this by using the -LiteralPath arg:

if( -not (Test-Path -LiteralPath -Path $Target -PathType Container) )

I can't see a good reason not to use the literal path in this scenario - creating junctions using wildcards isn't really an option.

Comments (3)

  1. Log in to comment