(:weight bold)))
"Face to show quoted execs like \\=`blabla\\=`."
:group 'sh-indentation)
-(define-obsolete-face-alias 'sh-heredoc-face 'sh-heredoc "22.1")
-(defvar sh-heredoc-face 'sh-heredoc)
(defface sh-escaped-newline '((t :inherit font-lock-string-face))
"Face used for (non-escaped) backslash at end of a line in Shell-script mode."
(if q
(if (characterp q)
(if (eq q ?\`) 'sh-quoted-exec font-lock-string-face)
- sh-heredoc-face)
+ 'sh-heredoc)
font-lock-comment-face)))
(defgroup sh-indentation nil
(setq-local skeleton-filter-function 'sh-feature)
(setq-local skeleton-newline-indent-rigidly t)
(setq-local defun-prompt-regexp
- (concat "^\\(function[ \t]\\|[[:alnum:]]+[ \t]+()[ \t]+\\)"))
+ (concat
+ "^\\("
+ "\\(function[ \t]\\)?[ \t]*[[:alnum:]]+[ \t]*([ \t]*)"
+ "\\|"
+ "function[ \t]+[[:alnum:]]+[ \t]*\\(([ \t]*)\\)?"
+ "\\)[ \t]*"))
(setq-local add-log-current-defun-function #'sh-current-defun-name)
(add-hook 'completion-at-point-functions
#'sh-completion-at-point-function nil t)
;;(This function never returns just t.)
(cond
((or (nth 3 (syntax-ppss (point)))
- (eq (get-text-property (point) 'face) sh-heredoc-face))
+ (eq (get-text-property (point) 'face) 'sh-heredoc))
;; String continuation -- don't indent
(setq result t)
(setq have-result t))
(forward-comment (- (point-max)))
(unless end (beginning-of-line))
(when (and (not (bobp))
- (equal (get-text-property (1- (point)) 'face)
- sh-heredoc-face))
+ (eq (get-text-property (1- (point)) 'face) 'sh-heredoc))
(let ((p1 (previous-single-property-change (1- (point)) 'face)))
(when p1
(goto-char p1)