Subject: bug#10586: 23.3; cd in remote shell reset working directory to local home

From: Glenn Morris <[email-masked]>
Date: Tue, 24 Jan 2012 13:19:38 -0500

Alberto wrote:

> Open a remote folder, e.g.
>     C-x C-f /onan:bin
> Open a remote shell there
>     M-x shell
> Check with pwd that working directory is remote
>     M-x pwd
> Execute in the shell cd
>     > cd
> Check with pwd that working directory is now _local_ home
>     M-x pwd

I can't reproduce this using Tramp's scpc method and don't see how such
a thing could even be possible. Is your local home directory even
visible on the remote machine? What tramp connection method are you
using? Does it happen with `emacs -Q'?

> After this happens the only way I found to fix the working directory
> is to kill the shell buffer and open it again.

Depending on the shell you use, does not 'cd -' take you back to the
previous directory?