aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/progmodes/sh-script.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/progmodes/sh-script.el')
-rw-r--r--lisp/progmodes/sh-script.el12
1 files changed, 9 insertions, 3 deletions
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index baed27bb138..394e9ca48c6 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -204,6 +204,7 @@
204 204
205(autoload 'comint-completion-at-point "comint") 205(autoload 'comint-completion-at-point "comint")
206(autoload 'comint-filename-completion "comint") 206(autoload 'comint-filename-completion "comint")
207(autoload 'comint-send-string "comint")
207(autoload 'shell-command-completion "shell") 208(autoload 'shell-command-completion "shell")
208(autoload 'shell-environment-variable-completion "shell") 209(autoload 'shell-environment-variable-completion "shell")
209 210
@@ -1450,7 +1451,7 @@ This is for the rc shell."
1450(defun sh-mkword-regexpr (word) 1451(defun sh-mkword-regexpr (word)
1451 "Make a regexp which matches WORD as a word. 1452 "Make a regexp which matches WORD as a word.
1452This specifically excludes an occurrence of WORD followed by 1453This specifically excludes an occurrence of WORD followed by
1453punctuation characters like '-'." 1454punctuation characters like `-'."
1454 (concat word "\\([^-[:alnum:]_]\\|$\\)")) 1455 (concat word "\\([^-[:alnum:]_]\\|$\\)"))
1455 1456
1456(defconst sh-re-done (sh-mkword-regexpr "done")) 1457(defconst sh-re-done (sh-mkword-regexpr "done"))
@@ -1580,7 +1581,8 @@ assumed. Since filenames rarely give a clue, they are not further analyzed.
1580This mode adapts to the variations between shells (see `sh-set-shell') by 1581This mode adapts to the variations between shells (see `sh-set-shell') by
1581means of an inheritance based feature lookup (see `sh-feature'). This 1582means of an inheritance based feature lookup (see `sh-feature'). This
1582mechanism applies to all variables (including skeletons) that pertain to 1583mechanism applies to all variables (including skeletons) that pertain to
1583shell-specific features. 1584shell-specific features. Shell script files can use the `sh-shell' local
1585variable to indicate the shell variant to be used for the file.
1584 1586
1585The default style of this mode is that of Rosenblatt's Korn shell book. 1587The default style of this mode is that of Rosenblatt's Korn shell book.
1586The syntax of the statements varies with the shell being used. The 1588The syntax of the statements varies with the shell being used. The
@@ -2364,7 +2366,11 @@ argument) controls whether to insert a #!-line and think about making
2364the visited file executable, and NO-QUERY-FLAG (the second argument) 2366the visited file executable, and NO-QUERY-FLAG (the second argument)
2365controls whether to query about making the visited file executable. 2367controls whether to query about making the visited file executable.
2366 2368
2367Calls the value of `sh-set-shell-hook' if set." 2369Calls the value of `sh-set-shell-hook' if set.
2370
2371Shell script files can cause this function be called automatically
2372when the file is visited by having a `sh-shell' file-local variable
2373whose value is the shell name (don't quote it)."
2368 (interactive (list (completing-read 2374 (interactive (list (completing-read
2369 (format "Shell (default %s): " 2375 (format "Shell (default %s): "
2370 sh-shell-file) 2376 sh-shell-file)