From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Doug Lewan Newsgroups: gmane.emacs.help Subject: RE: Shell scripting mode Date: Thu, 10 Oct 2013 14:01:28 +0000 Message-ID: <155DEC68569B714B86C2C7075F5EDA9852F9A9DC@DAKIYA1.pegasus.local> References: <87zjqi6by2.fsf@alumnos.upm.es> <87mwmhp881.fsf@alumnos.upm.es> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1381413710 28628 80.91.229.3 (10 Oct 2013 14:01:50 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 10 Oct 2013 14:01:50 +0000 (UTC) To: =?iso-8859-1?Q?Adri=E1n_Mart=EDnez_Larumbe?= , "help-gnu-emacs@gnu.org" Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Oct 10 16:01:53 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 1VUGoL-0001kI-0O for geh-help-gnu-emacs@m.gmane.org; Thu, 10 Oct 2013 16:01:53 +0200 Original-Received: from localhost ([::1]:47680 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VUGoK-00062a-N8 for geh-help-gnu-emacs@m.gmane.org; Thu, 10 Oct 2013 10:01:52 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57082) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VUGo6-00061x-2J for help-gnu-emacs@gnu.org; Thu, 10 Oct 2013 10:01:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VUGnx-0006FH-1N for help-gnu-emacs@gnu.org; Thu, 10 Oct 2013 10:01:37 -0400 Original-Received: from webmail.shubertorg.com ([207.246.209.200]:53967) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VUGnw-0006Eu-U7 for help-gnu-emacs@gnu.org; Thu, 10 Oct 2013 10:01:28 -0400 Original-Received: from dakiya1.pegasus.local ([172.16.208.201]) by DAKIYA1.pegasus.local ([172.16.208.201]) with mapi id 14.01.0438.000; Thu, 10 Oct 2013 10:01:29 -0400 Thread-Topic: Shell scripting mode Thread-Index: AQHOxPdQqxwuhLSRqkOHTcAcelJKopnt79f6gAACMmA= In-Reply-To: <87mwmhp881.fsf@alumnos.upm.es> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.0.21.202] X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 X-Received-From: 207.246.209.200 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:93916 Archived-At: Thanks for the list. Some of your suggestions are almost there already. (And maybe that's why th= ey're not all there. The community may have settled for "good enough".) Here are my thoughts: - Code completion ... M-/ comes close. I agree that something shell-specific would be a good = thing.=20 Handling previously defined functions from other files might be tricky. After all, which previously defined function from which other file soun= ds a little vague to me. - Navigation ... Exuberant ctags should do exactly what you want. (I don't think the etags that comes with emacs handles shell, but I cou= ld be wrong.) - Flymake for shell Not there. This would be *very* useful. Shells are so full of syntax that it's often very hard to find a mistak= e. - Interaction with lower process This would be very useful too. And probably not hard to write.=20 All the screwy syntax might mess such a thing up.=20 (Think unterminated string or an unterminated ${variable.) A command like M-x sh-eval-region that always starts (and terminates) a= clean shell might work though. - Online Documentation of shell builtins Info for bash is pretty good. Something that navigates it directly would indeed be nice. As far as other shells go, it's probably a hard thing to do. You'd have to get all the authors/publishers to definitively declare th= eir help locations, formats, etc. Better yet, they could all agree on one location, one format, etc. (Ha!= I made a joke!) - Yassnippet library Personally I'm happy typing almost everything in shell. (The exception is option handling.=20 I never remember if getopt or getopts is the built-in, and that's the o= ne I want.) I don't happen to know yassnippet since I use very few emacs applicatio= ns that aren't delivered with emacs. Sorry. ,Douglas Douglas Lewan Shubert Ticketing (201) 489-8600 ext 224 These are my principles and if you don't like them... well, I have others. = - Groucho Marx -----Original Message----- From: help-gnu-emacs-bounces+dougl=3Dshubertticketing.com@gnu.org [mailto:h= elp-gnu-emacs-bounces+dougl=3Dshubertticketing.com@gnu.org] On Behalf Of Ad= ri=E1n Mart=EDnez Larumbe Sent: Thursday, 2013 October 10 09:27 To: help-gnu-emacs@gnu.org Subject: Re: Shell scripting mode This is a short wishlist I've compiled that pretty much sums up everything I was looking for when I wrote the post: - Code completion of shell bultins and previously defined functions (I guess this could be done by writing a wordlist for autocomplete = mode) - Navigation: imenu, buffer definitions, etags, gtags? (I'm wondering whether etags has shell scripting support, I'll look this up myself) - Flymake for shell (There seems to be a mode for this on elpa repositories) - Interaction with lower process (It'd be awesome if I could send arbitrary regions into the shell for immediate execution) - Online Documentation of shell builtins (I guess the best way is turning to woman and reading the matching section) - Yassnippet library (The sh scripting mode that ships with emacs has predefined functions for skeletons of common constructs, but I think this is unnecessary if you put it all into a yasnipet mode directory)