Tassilo Horn <[EMAIL PROTECTED]> writes:
> Hi,
Hi,
> I'd like to have tramp buffers prefixed with the current method. For
> example if I open /ets/hosts with the sudo method, the buffer should be
> named "sudo:hosts" instead of only "hosts" so that I can easily use the
> usual buffer completion to distinguish between normal and tramp buffers.
>
> How can I achieve that?
(add-hook 'find-file-hook
'(lambda ()
(when (file-remote-p (buffer-file-name))
(rename-buffer
(format "%s:%s"
(file-remote-p (buffer-file-name) 'method)
(buffer-name))
'unique))))
> Thanks in advance,
> Tassilo
Best regards, Michael.
_______________________________________________
Tramp-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/tramp-devel