Windows equivalent to UNIX pwd

2019-01-16 02:14发布

How do I find the local path on windows in a command prompt?

标签: windows cmd pwd
9条回答
Emotional °昔
2楼-- · 2019-01-16 02:32

hmm - pwd works for me on Vista...

Final EDIT: it works for me on Vista because WinAvr installed pwd.exe and added \Program Files\WinAvr\Utils\bin to my path.

查看更多
叛逆
3楼-- · 2019-01-16 02:40

dir | find "Directory"

查看更多
We Are One
4楼-- · 2019-01-16 02:41

cd ,

it will give current directory

D:\Folder\subFolder>cd ,
D:\Folder\subFolder
查看更多
Luminary・发光体
5楼-- · 2019-01-16 02:42

It is cd for "current directory".

查看更多
爱情/是我丢掉的垃圾
6楼-- · 2019-01-16 02:43

cd without any parameters is equivalent to pwd on Unix/Linux.

From the console output of typing cd /?:

Displays the name of or changes the current directory.

[...]

Type CD without parameters to display the current drive and directory.
查看更多
The star\"
7楼-- · 2019-01-16 02:45

This prints it in the console:

echo %cd%

or paste this command in CMD, then you'll have pwd:

(echo @echo off
echo echo ^%cd^%) > C:\WINDOWS\pwd.bat
查看更多
登录 后发表回答