Long Paths

PowerShell, actually .Net on which it is built, has a limitation that no directory path can be longer than 248 characters and no file path longer than 260. See http://blogs.msdn.com/b/bclteam/archive/2007/02/13/long-paths-in-net-part-1-of-3-kim-hamilton.aspx As a result if you try to use powershell to traverse long paths you will get an error. "Get-ChildItem : The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters." There is no way to get around this limitation with native powershell.

Before we begin, it should be stated, the ultimate solution is to shorten long directory and filenames. Even though Windows NTFS can handle the long paths, it does slow file handling down.

Some workarounds.