System: Mac OSX catalina Emacs: 26.3

I use Ivy as my completion framework.

Problem is when I am editing a remote buffer over ssh using Tramp, and then I want to look at a file on my local machine.

If I do C-x C-f, I get my dialogue, but I can only see options for the remote machine. I can't delete my way out of the tramp listings. So what I do now is I first C-x b into the scratch buffer, then do C-x C-f to see local machine listings. Is there a way to do this in a more natural fashion?

For example when attached via tramp, hitting backspace/delete at this point does nothing further:


So I go the scratch buffer and then I can get this:

enter image description here

1 Answer 1


Is there a way to do this in a more natural fashion?

The best way I know is to type ~ twice: the first time will restart completion from your remote home directory, and the second from your local home directory.

Quoth (ivy) Using TRAMP:

‘/ C-j’
     Move to the local root directory.

     Move to the local home directory.
  • Oh @Basil thank you!!! This was driving me nuts. Now let me type some synonims of the question for another pour sool that like me is searchnig for this: How to get out of tramp? Tramp how to edit local files? Tramp insist in using remote server? Find local files in emacs?
    – elviejo79
    Commented Jun 27, 2020 at 17:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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