* tramp convinient way to cut path part in minibuffer
@ 2015-03-08 15:01 Paul K
2015-03-08 17:21 ` Michael Albinus
0 siblings, 1 reply; 3+ messages in thread
From: Paul K @ 2015-03-08 15:01 UTC (permalink / raw)
To: help-gnu-emacs
Hallo People
I'm going to open /scp:remote.linux.box:/etc/passwd.
Currently opened file is /scp:remote.linux.box:/var/log/messages,
thus pressing C-x C-f, produces following path to minibuffer:
/scp:remote.linux.box:/var/log/messages
Cursor is at the end of line of course.
Is there any key combination to move cursor `here`, so that I could cut
/etc/passwd and then put /var/log/messages path?
/scp:remote.linux.box:/var/log/messages
^
here.
Probably the perfect solution would be to force C-a to move cursor `here`
and another C-a to move cursor to beginning of line.
I'm opening many files on the same remote.linux.box, thus such solution
would be very helpful.
regards
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: tramp convinient way to cut path part in minibuffer
2015-03-08 15:01 tramp convinient way to cut path part in minibuffer Paul K
@ 2015-03-08 17:21 ` Michael Albinus
2015-03-08 19:57 ` Paul K
0 siblings, 1 reply; 3+ messages in thread
From: Michael Albinus @ 2015-03-08 17:21 UTC (permalink / raw)
To: Paul K; +Cc: help-gnu-emacs
Paul K <mafeuser@gmail.com> writes:
> Hallo People
Hi Paul,
> Is there any key combination to move cursor `here`, so that I could cut
> /etc/passwd and then put /var/log/messages path?
You don't need to cut /etc/passwd. If you enter two slashes "//" at the
end of the minibuffer, everything which is part of the local name on the
remote machine is ignored. Try this (given you have opened
/scp:remote.linux.box:/etc/passwd):
C-x C-f /var/log/messages
Since C-x C-f gives you the default path "/scp:remote.linux.box:/etc/"
in the minibuffer you can just start to type with "/var..." - the "/" of
"/var" adds the second slash.
Btw, three or more slashes "///" will ignore everything in the
minibuffer before them.
> regards
Best regards, Michael.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: tramp convinient way to cut path part in minibuffer
2015-03-08 17:21 ` Michael Albinus
@ 2015-03-08 19:57 ` Paul K
0 siblings, 0 replies; 3+ messages in thread
From: Paul K @ 2015-03-08 19:57 UTC (permalink / raw)
To: Michael Albinus; +Cc: help-gnu-emacs
Michael,
You again come with good news!
Although emacs has many great modules, tramp is my favourite one.
Thank You for even faster and more convenient way :)
best regards,
Paul
On Sun, Mar 8, 2015 at 6:21 PM, Michael Albinus <michael.albinus@gmx.de>
wrote:
> Paul K <mafeuser@gmail.com> writes:
>
> > Hallo People
>
> Hi Paul,
>
> > Is there any key combination to move cursor `here`, so that I could cut
> > /etc/passwd and then put /var/log/messages path?
>
> You don't need to cut /etc/passwd. If you enter two slashes "//" at the
> end of the minibuffer, everything which is part of the local name on the
> remote machine is ignored. Try this (given you have opened
> /scp:remote.linux.box:/etc/passwd):
>
> C-x C-f /var/log/messages
>
> Since C-x C-f gives you the default path "/scp:remote.linux.box:/etc/"
> in the minibuffer you can just start to type with "/var..." - the "/" of
> "/var" adds the second slash.
>
> Btw, three or more slashes "///" will ignore everything in the
> minibuffer before them.
>
> > regards
>
> Best regards, Michael.
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-03-08 19:57 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-08 15:01 tramp convinient way to cut path part in minibuffer Paul K
2015-03-08 17:21 ` Michael Albinus
2015-03-08 19:57 ` Paul K
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).