r/PowerShell • u/sundry_outlook • Apr 21 '26
PSDrive
Hi..
I have created a new PSDrive having name `S:`.
new-psdrive -name S -psprovider filesystem -root c:\users\username\dir
one running command `get-content` works fine, but `vim` is opening a blank file.
get-content S:\test.txt # works fine
vim S:\test.txt # opens a blank file
8
Upvotes
View all comments
Show parent comment
2
u/Over_Dingo Apr 21 '26
That's crazy, wonder what API it uses. It creates 2 entries in powershell, it is visible in explorer, and the root points to itself, not the destination drive (like in new-psdrive)
It's like a symlink that is a drive letter