unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Christopher Monsanto <chris@monsan.to>
To: 17158@debbugs.gnu.org
Subject: bug#17158: 24.4.50; sh-mode does not use auto-mode-interpreter-regexp to find shell type
Date: Tue, 1 Apr 2014 07:36:29 -0400	[thread overview]
Message-ID: <CAC5n7TEoiyXWpuxcAWCQ6LNHwPaafU0hcXn9eM=4Qs7Lei4mAw@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 603 bytes --]

See title; In sh-script.el, line ~1631

>    (cond ((save-excursion
>            (goto-char (point-min))
>           (looking-at "#![ \t]?\\([^ \t\n]*/bin/env[ \t]\\)?\\([^
\t\n]+\\)"))

This appears to duplicate auto-mode-interpreter-regexp in files.el, line
~2593:

> (defvar auto-mode-interpreter-regexp
>  (purecopy "#![ \t]?\\([^ \t\n]*\
/bin/env[ \t]\\)?\\([^ \t\n]+\\)")

This duplication makes it difficult to customize
auto-mode-interpreter-regexp. A discrepancy will cause the wrong shell type
(bash, ksh, csh, ...) to be selected.

Christopher Monsanto
chris@monsan.to  --  http://monsan.to/

[-- Attachment #2: Type: text/html, Size: 932 bytes --]

             reply	other threads:[~2014-04-01 11:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-01 11:36 Christopher Monsanto [this message]
2021-01-20  2:26 ` bug#17158: 24.4.50; sh-mode does not use auto-mode-interpreter-regexp to find shell type Lars Ingebrigtsen

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='CAC5n7TEoiyXWpuxcAWCQ6LNHwPaafU0hcXn9eM=4Qs7Lei4mAw@mail.gmail.com' \
    --to=chris@monsan.to \
    --cc=17158@debbugs.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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).