[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Create shell from ido

From: Andreas Röhler
Subject: Re: Create shell from ido
Date: Thu, 28 Jan 2010 11:46:00 +0100
User-agent: Thunderbird (X11/20081227)

José A. Romero L. wrote:
> On 28 Sty, 02:54, Nathaniel Flath <address@hidden> wrote:
>> Hello,
>> I have ido activated.  If I do C-x C-f and navigate to a directory, C-d will
>> open a dired buffer in that directory.  Is there a way to open a shell
>> buffer instead?
>> Thanks,
>> Nathaniel Flath
> Depends on the shell you want to use. For regular shell you could use
> something like this:
> (defun nf/openshell (&optional dir)
>   (interactive "DDirectory to open shell into: ")
>   (shell)
>   (if dir
>       (comint-send-string
>        (current-buffer)
>        (concat "cd " (shell-quote-wildcard-pattern dir) "
> "))))
> in any case, it doesn't seem  to be possible to open a shell directly
> in any  arbitrary directory other than  default-directory. 

It's not ido, but it should do it:

(defun My-Shell-where-I-want-it ()
 (dired "My-precious-directory")

Maybe adapt that for ido, if necessary.


> You always
> have to send a "cd something" to move to where you want to be (though
> I'd be glad to find out I'm wrong). In any case, that's the same I do
> in  SrC (  and works
> quite well for me.
> Cheers,
> --
> José A. Romero L.
> escherdragon at
> "We who cut mere stones must always be envisioning cathedrals."
> (Quarry worker's creed)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]