help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: eshell and jobs. THANK YOU KAI


From: Michael Spittel
Subject: Re: eshell and jobs. THANK YOU KAI
Date: 29 Jan 2003 07:16:25 -0600
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7

Kai,
Thank you for your reply.  Your code worked brilliantly!!!

Thank you very very much.

cheers,
mike

ps, Not knowing lisp, can you briefly explain what the code does?





kai.grossjohann@uni-duisburg.de (Kai Großjohann) writes:

> Michael Spittel <mspittel@kite.ssc.wisc.edu> writes:
> 
> > (nudge nudge Kai) :-)
> 
> I'm listening, but I'm afraid I can't help.  I don't know how to
> redirect the output of a command to a buffer.
> 
> Hm.  But I have this:
> 
> (defun eshell/ec (&rest args)
>   "Use `compile' to do background makes."
>   (if (eshell-interactive-output-p)
>       (let ((compilation-process-setup-function
>            (list 'lambda nil
>                  (list 'setq 'process-environment
>                        (list 'quote (eshell-copy-environment))))))
>       (compile (eshell-flatten-and-stringify args))
>         (pop-to-buffer compilation-last-buffer))
>     (throw 'eshell-replace-command
>            (let ((l (eshell-stringify-list (eshell-flatten-list args))))
>              (eshell-parse-command (car l) (cdr l))))))
> (put 'eshell/ec 'eshell-no-numeric-conversions t)
> 
> This this code, you can do 
> 
>     ec ls -l
> 
> and the output of ls -l will go to a separate buffer.  It's not the
> same as redirection, but maybe it's good enough?
> -- 
> Ambibibentists unite!

-- 
-Mike Spittel

--------------------------------------------------------------------
Michael Ludwig Spittel    O    (=> Center for Demography and Ecology
  Tel: (608) 256-7742   )/\_,_[__] University of Wisconsin-Madison  
  Fax: (608) 262-8400   T>_   |  | 1180 Observatory DR.             
Email: mspittel@ssc.wisc.edu  +  + Madison, WI  53706               
--------------------------------------------------------------------


reply via email to

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