(eshell-script-interpreter): Fix for CRLF operating systems to the
authorJohn Wiegley <johnw@newartisans.com>
Fri, 12 Apr 2002 20:11:06 +0000 (20:11 +0000)
committerJohn Wiegley <johnw@newartisans.com>
Fri, 12 Apr 2002 20:11:06 +0000 (20:11 +0000)
regexp used to detect a script's interpretor.

lisp/eshell/esh-ext.el

index af7c240..12edbdc 100644 (file)
@@ -257,7 +257,7 @@ Return nil, or a list of the form:
             (file-regular-p file))
        (with-temp-buffer
          (insert-file-contents-literally file nil 0 maxlen)
-         (if (looking-at "#![ \t]*\\([^ \t\n]+\\)\\([ \t]+\\(.+\\)\\)?")
+         (if (looking-at "#![ \t]*\\([^ \r\t\n]+\\)\\([ \t]+\\(.+\\)\\)?")
              (if (match-string 3)
                  (list (match-string 1)
                        (match-string 3)