Reputation: 18585
If I open up 2 terminals in Ubuntu, via ps u
I can see 2 bash
's pid
.
My problem is from one terminal, how can I know the bash
's cwd in the other terminal?
Upvotes: 0
Views: 4552
Reputation: 685
The pwdx
command prints the current working directory of each given process ID.
Example from Solaris (believe Ubuntu also has the command):-
$ cd /tmp
$ pwdx $$
22281: /tmp
Upvotes: 2