You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As I put Cmder at D:\Programs\Cmder, every time when I change directory by:
D:
cd/d D:
cmder /single "D:"
It will goes to D:\Programs\Cmder\config\profile.d actually.
And I've noticed something like below (the C: goes to %HOME% is the same as Windows's Cmd):
Given path with / means the absolute path, it's obvious.
Without /, it seems like it will goes to the HOME folder but I'm not sure.
Any explanation?
The text was updated successfully, but these errors were encountered:
Windows' Cmd will remember the last directory of the disk you've worked at, and when you cd back to the same disk (without /), it will be there.
Same behavior will be seen on Cmder, so we could conclude this: Cmder's last working directory is %CMDER_ROOT%/config/profile.d, which means Cmder runs cmd.exe at this path, and then goes to the real destination, e.g. %HOME%.
If the target path's disk is the same as %CMDER_ROOT%'s, it's no problem.
So, if you want to make a change, go set some init scripts to cd to the root of this disk. ;-)
:: %CMDER_ROOT%\config\user-profile.cmdset"init_current_path=%cd%"cd /d D:/
cd /d %init_current_path%setinit_current_path=
But it will not change cmder /single "D:"'s behavior.
*.{bat|cmd}s at %CMDER_ROOT%/config/profile.d are going to be init scripts, where we may know the reason for it becomes the last path Cmder worked at before program getting ready.
hyrious
changed the title
cd/d D:' always goes to D:\Programs\Cmder\config\profile.d'cd/d D: always goes to D:\Programs\Cmder\config\profile.dSep 21, 2020
As I put Cmder at
D:\Programs\Cmder
, every time when I change directory by:D: cd/d D: cmder /single "D:"
It will goes to
D:\Programs\Cmder\config\profile.d
actually.And I've noticed something like below (the
C:
goes to%HOME%
is the same as Windows's Cmd):/
means the absolute path, it's obvious./
, it seems like it will goes to theHOME
folder but I'm not sure.Any explanation?
The text was updated successfully, but these errors were encountered: