unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: "Andreas Röhler" <andreas.roehler@easy-emacs.de>
To: jidanni@jidanni.org
Cc: help-gnu-emacs@gnu.org, bug-gnu-emacs@gnu.org
Subject: Re: how to map sh-mode to mean bash-mode
Date: Mon, 18 Jul 2011 07:52:04 +0200	[thread overview]
Message-ID: <4E23CA04.3000007@easy-emacs.de> (raw)
In-Reply-To: <871uxovdtu.fsf@jidanni.org>

Am 17.07.2011 22:42, schrieb jidanni@jidanni.org:
> Dear bug-gnu-emacs,
> There is no way to map sh-mode to bash-mode.

Again: AFAIK there no such thing like `bash-mode' in Emacs.

There is a `sh-mode' dealing with several kind of shells.
If `sh-mode' thinks you are dealing with a bash -- by shebang or 
suffix-- it provides for it. An alias is called `shell-script-mode'

See C-h f shell-script-mode RET

for what it does.

> As you know, the bash shell likes to call itself sh sometimes.

Didn't know that. Curious to read an example.

> But it is really still bash.
Well, bash might use a sh as a subset. Don't know that architecture.

> Hence I would like to make my emacs assume anything it thinks is sh is
> really bash, and thus show me "bash" in the mode line, not "sh", no
> matter how smart it thinks it is.

Could you deliver an example of usage for that?
If you send code written for a bash to a simple sh - some may work, 
others will fail.
You are surely implementing bugs then.


  See also
> http://lists.gnu.org/archive/html/help-gnu-emacs/2011-07/msg00143.html
> However the real solution should be a one liner of lisp in ones .emacs.
>

What's great about a one-liner? Usually they are hard to read.




  reply	other threads:[~2011-07-18  5:52 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-15 23:58 how to map sh-mode to mean bash-mode jidanni
2011-07-17  9:26 ` Andreas Röhler
2011-07-17 14:25   ` Perry Smith
2011-07-17 17:30     ` Andreas Röhler
2011-07-17 17:48     ` Andreas Röhler
2011-07-17 20:42       ` bug#9110: " jidanni
2011-07-18  5:52         ` Andreas Röhler [this message]
2011-07-18  8:19           ` Peter Dyballa
2011-07-18  8:31             ` Andreas Röhler
2011-07-18  8:40               ` Peter Dyballa
2011-07-26  5:43     ` Kevin Rodgers
     [not found] <jwvpqla4326.fsf-monnier+gnu.emacs.help@gnu.org>
2011-07-18  4:51 ` jidanni
2011-07-19 23:25 ` jidanni

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E23CA04.3000007@easy-emacs.de \
    --to=andreas.roehler@easy-emacs.de \
    --cc=bug-gnu-emacs@gnu.org \
    --cc=help-gnu-emacs@gnu.org \
    --cc=jidanni@jidanni.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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).