From: Thierry Volpiatto <thierry.volpiatto@gmail.com>
To: emacs-devel@gnu.org
Subject: Re: [PATCH] minibuffer issue with eshell-command
Date: Mon, 10 Oct 2011 20:36:54 +0200 [thread overview]
Message-ID: <87y5wsvgl5.fsf@gmail.com> (raw)
In-Reply-To: 87botsobtk.fsf@gmail.com
Thierry Volpiatto <thierry.volpiatto@gmail.com> writes:
Hi, i made some simplifications to my last patch and fix also a little
error:
When command is called from lisp, `eshell-add-input-to-history' should
not add history to ring. (this cause an error).
Here the patch:
diff --git a/lisp/eshell/eshell.el b/lisp/eshell/eshell.el
index c33c2cc..0c1c039 100644
--- a/lisp/eshell/eshell.el
+++ b/lisp/eshell/eshell.el
@@ -349,11 +349,9 @@ With prefix ARG, insert output into the current buffer at point."
(minibuffer-with-setup-hook #'(lambda ()
(eshell-mode)
(eshell-return-exits-minibuffer))
- (unwind-protect
- (unless command
- (setq command (read-from-minibuffer "Emacs shell command: ")))
- (when command
- (eshell-add-input-to-history command)))))
+ (unless command
+ (setq command (read-from-minibuffer "Emacs shell command: "))
+ (eshell-add-input-to-history command))))
(unless command
(error "No command specified!"))
;; redirection into the current buffer is achieved by adding an
If no objections i will install it tomorrow.
--
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997
prev parent reply other threads:[~2011-10-10 18:36 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-06 7:09 [PATCH] minibuffer issue with eshell-command Thierry Volpiatto
2011-10-06 12:48 ` Thierry Volpiatto
2011-10-06 15:00 ` Chong Yidong
2011-10-06 15:36 ` Stefan Monnier
2011-10-06 16:22 ` Thierry Volpiatto
2011-10-07 14:04 ` Thierry Volpiatto
2011-10-07 19:12 ` Thierry Volpiatto
2011-10-10 18:36 ` Thierry Volpiatto [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87y5wsvgl5.fsf@gmail.com \
--to=thierry.volpiatto@gmail.com \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.