PSHELL's CWD

samintz

Scott Mintz
May 20, 2008
1,332
12
Solon, OH, USA
Is this behavior expected? I.e. the default directory changes from 'C:\temp' to 'C:\users\mintz\documents' for the PSHELL command.
Code:
[C:\Temp]
$ pshell /s "pwd"

Path
----
C:\Users\mintz\Documents

[C:\Temp]
$ powershell -command "PWD"

Path
----
C:\Temp
 
May 20, 2008
9,350
62
Syracuse, NY, USA
Same here. IMHO, the second is preferred.
Code:
v:\> pshell /s "pwd"

Path
----
C:\Users\vefatica\Documents



v:\> powershell -command "PWD"

Path
----
V:\