Repository navigation
Move-Action: pasting script paths inside URN directory doesn't recognize paths as valid. #28354
Replies: 1 comment
|
Since Tab completion fixes it, the pasted path doesn't match the real file name exactly as PowerShell reads it. Two common causes, and both are easy to check: 1. Square brackets in the file or folder name. Move-Item -LiteralPath '.\bar.ext' -Destination '.\foo\bar-rename.ext'2. An invisible or look-alike character from wherever you copied the text. A non-breaking space, an en dash instead of '<paste the path here>'.ToCharArray() | ForEach-Object { '{0} {1:X4}' -f $_, [int]$_ }If it's this one, fixing the source text (or typing those characters by hand) solves it. The network location itself shouldn't matter. Relative paths like |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
My time for bug hunting is limited, I'm a drafter by trade and there's only so much time I can spend on the clock on this. The gist is that when the working directory is inside a URN directory on my company network, pasting a move action into Powershell (which I have to do since I can't execute scripts) Powershell does not interpret the paths I've pasted as valid paths.
However, if I don't execute the script, I can arrow key to the first path, erase the extension, and hit tab to autocomplete the file, Powershell interprets this fine.
It's possible that Pasted UTF-8 characters into PowerShell shell are interpreted incorrectly.
#24037 is related, Mr Beedell, Roke Julian Lockhart (@beedell-roke) there suggested I start a thread over here.
All reactions