12

I am getting 'pwd' is not recognized as an internal or external command operable program or batch file when I am trying to check my present working directory from cmd.

I have already set the environment variable path. Still I am getting the issue. ping, cmd is working fine.

Please help. thanks in advance

user207421
  • 298,294
  • 41
  • 291
  • 462
Sanil Jain
  • 147
  • 1
  • 1
  • 4
  • 1
    `System.getProperty("user.dir")` – Elliott Frisch Oct 09 '17 at 04:05
  • 1
    Or else [tag:java] has nothing to do with your question. – user207421 Oct 09 '17 at 04:08
  • 1
    Possible duplicate of [What is the reason for '...' is not recognized as an internal or external command, operable program or batch file?](https://stackoverflow.com/questions/41454769/what-is-the-reason-for-is-not-recognized-as-an-internal-or-external-comman) – Mofi Oct 09 '17 at 05:31

3 Answers3

20

pwd is a linux command, won't work in windows.

In windows just run cd without passing any arguments

Ramanlfc
  • 8,108
  • 1
  • 16
  • 24
  • This works on my windows development machine. It works in cmd.exe. I'd be interested to know why it works. I did install Git Bash. – P.Brian.Mackey Nov 19 '18 at 20:02
2

'pwd' works on "windows Powershell" instead of "command prompt/cmd" from windows 10

1

If you are using JupyterLab, !pwd is unacceptable as it is for the the linux, for window use pwd ,instead.

swm
  • 41
  • 1
  • 9