From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Pascal J. Bourguignon" Newsgroups: gmane.emacs.help Subject: Re: shell-like Emacs CLI, and my Usenet behaviour Date: Sun, 18 Aug 2013 23:04:43 +0200 Organization: Informatimago Message-ID: <874namlnh0.fsf@informatimago.com> References: <87eh9qpznc.fsf@nl106-137-194.student.uu.se> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1376860217 30750 80.91.229.3 (18 Aug 2013 21:10:17 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 18 Aug 2013 21:10:17 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Aug 18 23:10:21 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VBAEu-0004jL-1g for geh-help-gnu-emacs@m.gmane.org; Sun, 18 Aug 2013 23:10:20 +0200 Original-Received: from localhost ([::1]:40032 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VBAEt-00083f-Js for geh-help-gnu-emacs@m.gmane.org; Sun, 18 Aug 2013 17:10:19 -0400 Original-Path: usenet.stanford.edu!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 66 Original-X-Trace: individual.net pb4kpBeZ6GBLUjT7KVSFpg3kLnsp+ABXEfS1ZHfgPXtdRovLDM Cancel-Lock: sha1:ZjZiNzAyNTdhMmQ0MmY3MGRhZGJhODg4ZGEyZGQxYjFhMDhmZDcyYg== sha1:BuAI5HEejQmIPLUo0CmV39aBIRc= Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA oElEQVR4nK3OsRHCMAwF0O8YQufUNIQRGIAja9CxSA55AxZgFO4coMgYrEDDQZWPIlNAjwq9 033pbOBPtbXuB6PKNBn5gZkhGa86Z4x2wE67O+06WxGD/HCOGR0deY3f9Ijwwt7rNGNf6Oac l/GuZTF1wFGKiYYHKSFAkjIo1b6sCYS1sVmFhhhahKQssRjRT90ITWUk6vvK3RsPGs+M1RuR mV+hO/VvFAAAAABJRU5ErkJggg== X-Accept-Language: fr, es, en User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) Original-Xref: usenet.stanford.edu gnu.emacs.help:200700 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:92965 Archived-At: Emanuel Berg writes: > After getting into several firefights, not just here but all over > Usenet, I have decided to change my behaviour. So it happened, > that my laptop (an old warhorse Dell Inspiron 1300), fell out of > my backpack, and broke (but I salvaged the HDD), and I am a > non-religious, "rational" believer in karma, so I interpreted this > as a sign that I should change my behaviour, and not be so easily > provoked, or as confrontational/high-energy in style. > > But, not dwelling on the past, I have been thinking if not Emacs > would benefit from a shell-like CLI, instead of hammering the RET > between each stage? > > Is this a new idea or did anyone do work on it? > > There are several advantages: > > For a simple example, the advantage is speed, less typing, and no > visual "reorient" after the RET. > > In a shell: > > man emacs RET man SPC emacs RET > In Emacs: > > M-x man RET emacs RET The only thing that's earned in typing SPC instead of RET is that it doesn't lock you in the command man. Perhaps you wanted actually woman, so you can C-a wo RET before the final RET. Now since emacs is a modeless editor, you couldn't (a-priori) edit the commands in the same buffer as the normal text, so you would have to switch to a command buffer. C-x b *command-buffer RET man SPC emacs RET C-x b pgm.txt RET begins to feel much less interesting than: M-x man RET emacs RET otherwise, it is possible to edit commands directly in normal buffers. In emacs, in most modes, C-x C-e is left bound to eval-last-sexp, so you can always type (man "emacs") C-x C-e in any buffer. You could write a command, bound for example to C-RET, that would take the text on the current line and interpret it as an emacs command. So you could type: RET man SPC emacs C-RET instead of M-x man RET emacs RET Still no obvious gain. Actually, it may be quite useful to have such a command, or otherwise a way to insert command "buttons" in any text buffer. It's rather easy to implement in emacs. -- __Pascal Bourguignon__ http://www.informatimago.com/