all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* eshell and quick cd
@ 2009-03-28  5:37 henry atting
  2009-03-28  5:51 ` thierry.volpiatto
       [not found] ` <mailman.4141.1238219904.31690.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 5+ messages in thread
From: henry atting @ 2009-03-28  5:37 UTC (permalink / raw)
  To: help-gnu-emacs

I recently encountered `wcd' [1], which provides a way to quickly change
directories. For example if I am in ~/a/b and want to cd to ~/c/def a
`wcd def' would suffice if def is a unique directory name.
Since only `cd' is allowed to change directories you have to write a
function in your ~/.zshrc (in my case) like that:

function wcd
{
  $HOME/bin/wcd.exe $*
. $HOME/bin/wcd.go
}

Is there already a builtin function of eshell which does the same? Or,
if not, how can I tell eshell to use wcd?

henry

___

[1] http://www.xs4all.nl/~waterlan/


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: eshell and quick cd
  2009-03-28  5:37 eshell and quick cd henry atting
@ 2009-03-28  5:51 ` thierry.volpiatto
       [not found] ` <mailman.4141.1238219904.31690.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 5+ messages in thread
From: thierry.volpiatto @ 2009-03-28  5:51 UTC (permalink / raw)
  To: help-gnu-emacs


Hi,
you have a very nice file called esh-toggle.el, you will find here:

ftp://ftp.newartisans.com/pub/emacs/

It should be integrated in emacs, this file is in the git repo of eshell
also but i can't find back url.

henry atting <nsmp_01@online.de> writes:

> I recently encountered `wcd' [1], which provides a way to quickly change
> directories. For example if I am in ~/a/b and want to cd to ~/c/def a
> `wcd def' would suffice if def is a unique directory name.
> Since only `cd' is allowed to change directories you have to write a
> function in your ~/.zshrc (in my case) like that:
>
> function wcd
> {
>   $HOME/bin/wcd.exe $*
> . $HOME/bin/wcd.go
> }
>
> Is there already a builtin function of eshell which does the same? Or,
> if not, how can I tell eshell to use wcd?
>
> henry
>
> ___
>
> [1] http://www.xs4all.nl/~waterlan/
>

-- 
A + Thierry Volpiatto
Location: Saint-Cyr-Sur-Mer - France





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: eshell and quick cd
       [not found] ` <mailman.4141.1238219904.31690.help-gnu-emacs@gnu.org>
@ 2009-03-29  9:35   ` henry atting
  2009-03-29 13:30     ` thierry.volpiatto
       [not found]     ` <mailman.4199.1238333835.31690.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 5+ messages in thread
From: henry atting @ 2009-03-29  9:35 UTC (permalink / raw)
  To: help-gnu-emacs

On Sa, Mär 28 2009, thierry.volpiatto@gmail.com wrote:

> Hi,
> you have a very nice file called esh-toggle.el, you will find here:
>
> ftp://ftp.newartisans.com/pub/emacs/
>
> It should be integrated in emacs, this file is in the git repo of eshell
> also but i can't find back url.
>
> henry atting <nsmp_01@online.de> writes:
>
>> I recently encountered `wcd' [1], which provides a way to quickly change
>> directories. For example if I am in ~/a/b and want to cd to ~/c/def a
>> `wcd def' would suffice if def is a unique directory name.
>> Since only `cd' is allowed to change directories you have to write a
>> function in your ~/.zshrc (in my case) like that:
>>
>> function wcd
>> {
>>   $HOME/bin/wcd.exe $*
>> . $HOME/bin/wcd.go
>> }
>>
>> Is there already a builtin function of eshell which does the same? Or,
>> if not, how can I tell eshell to use wcd?
>>
>> henry
>>
>> ___
>>
>> [1] http://www.xs4all.nl/~waterlan/
>>

esh-toogle is very handy, thanks.

But if I want to stay on the eshell command-line I still would like
eshell to use the above mentioned function. How can it be implemented in
eshell?

henry


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: eshell and quick cd
  2009-03-29  9:35   ` henry atting
@ 2009-03-29 13:30     ` thierry.volpiatto
       [not found]     ` <mailman.4199.1238333835.31690.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 5+ messages in thread
From: thierry.volpiatto @ 2009-03-29 13:30 UTC (permalink / raw)
  To: help-gnu-emacs

henry atting <nsmp_01@online.de> writes:

> On Sa, Mär 28 2009, thierry.volpiatto@gmail.com wrote:
>
>> Hi,
>> you have a very nice file called esh-toggle.el, you will find here:
>>
>> ftp://ftp.newartisans.com/pub/emacs/
>>
>> It should be integrated in emacs, this file is in the git repo of eshell
>> also but i can't find back url.
>>
>> henry atting <nsmp_01@online.de> writes:
>>
>>> I recently encountered `wcd' [1], which provides a way to quickly change
>>> directories. For example if I am in ~/a/b and want to cd to ~/c/def a
>>> `wcd def' would suffice if def is a unique directory name.
>>> Since only `cd' is allowed to change directories you have to write a
>>> function in your ~/.zshrc (in my case) like that:
>>>
>>> function wcd
>>> {
>>>   $HOME/bin/wcd.exe $*
>>> . $HOME/bin/wcd.go
>>> }
>>>
>>> Is there already a builtin function of eshell which does the same? Or,
>>> if not, how can I tell eshell to use wcd?
>>>
>>> henry
>>>
>>> ___
>>>
>>> [1] http://www.xs4all.nl/~waterlan/
>>>
>
> esh-toogle is very handy, thanks.
>
> But if I want to stay on the eshell command-line I still would like
> eshell to use the above mentioned function. How can it be implemented in
> eshell?

May be write your function in a little script instead of writing it in
your .zshrc/.bashrc.
You can also easily create alias with eshell.

-- 
A + Thierry Volpiatto
Location: Saint-Cyr-Sur-Mer - France





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: eshell and quick cd
       [not found]     ` <mailman.4199.1238333835.31690.help-gnu-emacs@gnu.org>
@ 2009-03-30 13:45       ` henry atting
  0 siblings, 0 replies; 5+ messages in thread
From: henry atting @ 2009-03-30 13:45 UTC (permalink / raw)
  To: help-gnu-emacs

On So, Mär 29 2009, thierry.volpiatto@gmail.com wrote:

> May be write your function in a little script instead of writing it in
> your .zshrc/.bashrc.
> You can also easily create alias with eshell.

I think I have to write an eshell function. wcd.exe is a binary (which
cannot be renamed on unix systems) that writes the destination
directory in wcd.go, which makes the change happen in the first place:

,----
| function wcd
|  {
|    $HOME/bin/wcd.exe $*
|  . $HOME/bin/wcd.go
|  }
`----


I don't know who to handle the dot part of the above function in elisp,
can anyone give me a hint?

henry


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-03-30 13:45 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-28  5:37 eshell and quick cd henry atting
2009-03-28  5:51 ` thierry.volpiatto
     [not found] ` <mailman.4141.1238219904.31690.help-gnu-emacs@gnu.org>
2009-03-29  9:35   ` henry atting
2009-03-29 13:30     ` thierry.volpiatto
     [not found]     ` <mailman.4199.1238333835.31690.help-gnu-emacs@gnu.org>
2009-03-30 13:45       ` henry atting

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.