-4

Does wd: in jobs show

  • the current working directory of each job, or
  • the previous working directory when invoking each job?

Can you demonstrate it or quote from some references?

I was under the impression of the second one when asking Does `ps` provide the working directory of each process?, but the replies seem all about the first one.

0

Jobs prints the working directory the shell had when starting the related job.

What later happens is not in the scope of the shell.

  • Thanks. Can you demonstrate it or quote from some references? – Tim Jul 29 '18 at 20:30
  • Check the last function in the file sh/xec.c from the Bourne Shell in schilytools. – schily Jul 29 '18 at 20:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.