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

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

Re: How to start shell and rename the buffer


From: Teemu Likonen
Subject: Re: How to start shell and rename the buffer
Date: Thu, 15 Jan 2009 16:40:01 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (gnu/linux)

tyler (2009-01-15 10:23 -0400) wrote:

> This works for me:
>
> emacs -title mytitle --eval '(progn (shell) (rename-buffer "myshell"))'
>
> I guess the --eval flag runs only the first complete command,
> requiring the (progn ...) to do both. Just guessing, though.

That is true. An example:

    $ emacs --batch -Q --eval '(message "one") (message "two")'
    one

So either wrap the commands inside a form which allows separate commands
(progn, let, ...) or use separate --eval options:

    $ emacs --batch -Q --eval '(progn (message "one") (message "two"))'
    one
    two

    $ emacs --batch -Q --eval '(message "one")' --eval '(message "two")'
    one
    two




reply via email to

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