[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/backports-25.2 5266c11 13/46: Allow more shell scr
From: |
Noam Postavsky |
Subject: |
[Emacs-diffs] scratch/backports-25.2 5266c11 13/46: Allow more shell script defun forms |
Date: |
Sun, 2 Oct 2016 14:04:48 +0000 (UTC) |
branch: scratch/backports-25.2
commit 5266c1180e3263aebcc2c1020457fe03ce74e61a
Author: Carlos Pita <address@hidden>
Commit: Noam Postavsky <address@hidden>
Allow more shell script defun forms
* lisp/progmodes/sh-script.el (sh-mode): Allow more shell
script defun forms, like function name () {...} (bug#19754).
(cherry picked from commit c817549b520ce3b10a949f00fcabf8a3a62697ae)
---
lisp/progmodes/sh-script.el | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index f089c81..789bc86 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -1662,7 +1662,12 @@ with your script for an edit-interpret-debug cycle."
(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)
- [Emacs-diffs] branch scratch/backports-25.2 created (now eb5dd2c), Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 25895c4 02/46: Doc fix for url-http, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 2284444 08/46: Require that the buffer that we're trying to patch exist, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 7d89389 04/46: Make erc connect asynchronously, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 0d9709e 19/46: Meta + shift + Fn combos are recognized by xterm>=216., Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 5266c11 13/46: Allow more shell script defun forms,
Noam Postavsky <=
- [Emacs-diffs] scratch/backports-25.2 fbe5f7b 11/46: Completely ignore buffers with no name when copying file names, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 70244eb 15/46: Allow highlighting things like @math{2^{12}}, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 95d5520 12/46: Allow optional parameter to be nil, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 0780aa5 16/46: Replace XXX acronyms with draft standard ones, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 5f4c54b 18/46: Declare $ as an expression prefix in SCSS, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 344bc2b 17/46: Strip out some leading whitespace when looking at logs, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 69e0e89 23/46: Handle auth-source items with special characters on OS X, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 1cd6309 14/46: Allow ff-find-other-file (etc) to work with indirect clone buffers, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 5c084d9 10/46: Remove spurious newline in package list, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 80cf0b6 21/46: Restore the fix to bug#18527 from commit d6868025, Noam Postavsky, 2016/10/02