From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Endless Story" Newsgroups: gmane.emacs.help Subject: Re: Writing an interactive function to accept a string argument, then call a Python script? Date: 13 Feb 2007 03:21:21 -0800 Organization: http://groups.google.com Message-ID: <1171365681.355908.131220@k78g2000cwa.googlegroups.com> References: <1171026496.713032.169290@v33g2000cwv.googlegroups.com> <1171105054.246773.140640@p10g2000cwp.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: sea.gmane.org 1171366884 3714 80.91.229.12 (13 Feb 2007 11:41:24 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 13 Feb 2007 11:41:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Feb 13 12:41:16 2007 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HGw27-0007US-Kg for geh-help-gnu-emacs@m.gmane.org; Tue, 13 Feb 2007 12:41:15 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HGw26-0005zC-LO for geh-help-gnu-emacs@m.gmane.org; Tue, 13 Feb 2007 06:41:14 -0500 Original-Path: shelby.stanford.edu!headwall.stanford.edu!newsfeed.news2me.com!nx02.iad01.newshosting.com!newshosting.com!216.196.98.140.MISMATCH!border1.nntp.dca.giganews.com!nntp.giganews.com!postnews.google.com!k78g2000cwa.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 36 Original-NNTP-Posting-Host: 162.84.222.82 Original-X-Trace: posting.google.com 1171365696 417 127.0.0.1 (13 Feb 2007 11:21:36 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Tue, 13 Feb 2007 11:21:36 +0000 (UTC) In-Reply-To: User-Agent: G2/1.0 X-HTTP-UserAgent: Opera/9.02 (X11; Linux i686; U; en),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: k78g2000cwa.googlegroups.com; posting-host=162.84.222.82; posting-account=JP8pbg0AAADYDr61n41ZYs45c0xuivey Original-Xref: shelby.stanford.edu gnu.emacs.help:145555 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:41159 Archived-At: On Feb 13, 6:20 am, Kevin Rodgers wrote: > > Just curious: Is the `M' interactive code necessary in your experience? > I've always just used `s'. Well, since I was hacking it out blindly, I grabbed the first thing I saw in the GNU Emacs Lisp Reference Manual that looked like it should work. I guess M is fancier than s, but both will work in this instance - from the manual: 'M' Arbitrary text, read in the minibuffer using the current buffer's input method, and returned as a string (see Input Methods). Prompt. 's' Arbitrary text, read in the minibuffer and returned as a string (see Text from Minibuffer). Terminate the input with either C-j or . (C-q may be used to include either of these characters in the input.) Prompt. Meanwhile, since you're into lisp, I have a question for you: Would there be any real advantage to my learning it, aside from customizing Emacs beyond the things that other people have done that I can find on the Web? My impression is that the answer is no. I'm really just a writer who stumbled into scripting by accident, during a few years when I was documenting software as a technical writer. I enjoy fiddling with code mostly to automate various things I do with text processing. Python has been perfect for this purpose - easy to learn, easy to put down and then pick up again every few months as needed. I once thought about learning lisp - in fact I went so far as to buy "The Little Schemer" - but in the end I decided I could no more afford to take the time to learn it than I could continue to learn C, which I once dabbled in briefly for fun.