Categories

PowerShell pack: Mount-SpecialFolder

Special folders are things like Favourites, Desktop and StartMenu folders.  The Mount-SpecialFolder mounts one specified special folder or all special folders.  The folders involved can be found by using the .NET enumeration used to discover them.

PS>  [Enum]::GetValues([Environment+SpecialFolder])
Desktop
Programs
Personal
Personal
Favorites
Startup
Recent
SendTo
StartMenu
MyMusic
DesktopDirectory
MyComputer
Templates
ApplicationData
LocalApplicationData
InternetCache
Cookies
History
CommonApplicationData
System
ProgramFiles
MyPictures
CommonProgramFiles

There are some special folders missing for instance the recycle bin.  The folders can be mounted by importing the Filesystem module and using the Mount-SpecialFolder function.  Supply a folder name and it is mounted as a PowerShell drive.  Just use the function name and all special folders are mounted.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>