summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2023-04-15 12:44:48 -0400
committerEli Zaretskii <eliz@gnu.org>2023-04-15 12:44:48 -0400
commit709d55804798254b9b431ceac2e65d255fe031d5 (patch)
tree8f02e888c025ba5adf68e65f44a9281800184eb8 /lisp
parent0fe7fef54bb93fe02bf7313cfe65c4b6b455a785 (diff)
parentc62afb10cf0bbeae6a540f4e05b7a23536636cd0 (diff)
downloademacs-709d55804798254b9b431ceac2e65d255fe031d5.tar.gz
Merge from origin/emacs-29
c62afb10cf0 Fix wallpaper-tests on MS-Windows f2d212c6966 Fix a couple of eglot-tests 338b3718b6c Fix visiting RPM files b4afee03193 Fix ff-quiet-mode doc 2445100d7d6 ; Improve documentation of 'match-buffers' d4d0da96f0b ; Update make-tarball.txt for Emacs 29. 9b0bf694da4 ; Fix ldefs-boot.el. 0cb86a348c7 ; Update ChangeLog.4. # Conflicts: # ChangeLog.4
Diffstat (limited to 'lisp')
-rw-r--r--lisp/find-file.el4
-rw-r--r--lisp/progmodes/sh-script.el20
-rw-r--r--lisp/subr.el13
3 files changed, 21 insertions, 16 deletions
diff --git a/lisp/find-file.el b/lisp/find-file.el
index e98ea621d6a..05459c3643d 100644
--- a/lisp/find-file.el
+++ b/lisp/find-file.el
@@ -167,7 +167,7 @@ To override this, give an argument to `ff-find-other-file'."
:type 'boolean)
(defcustom ff-quiet-mode nil
- "If non-nil, trace which directories are being searched."
+ "If non-nil, do not trace which directories are being searched."
:type 'boolean)
;;;###autoload
@@ -351,7 +351,7 @@ Variables of interest include:
If non-nil, always attempt to create the other file if it was not found.
- `ff-quiet-mode'
- If non-nil, traces which directories are being searched.
+ If non-nil, does not trace which directories are being searched.
- `ff-special-constructs'
A list of regular expressions specifying how to recognize special
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index a5428a9a714..0cde1f387e0 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -1539,13 +1539,7 @@ implementations. Currently there are two: `sh-mode' and
(lambda (terminator)
(if (eq terminator ?')
"'\\'"
- "\\")))
- ;; Parse or insert magic number for exec, and set all variables depending
- ;; on the shell thus determined.
- (sh-set-shell (sh--guess-shell) nil nil)
- (add-hook 'flymake-diagnostic-functions #'sh-shellcheck-flymake nil t)
- (add-hook 'hack-local-variables-hook
- #'sh-after-hack-local-variables nil t))
+ "\\"))))
;;;###autoload
(define-derived-mode sh-mode sh-base-mode "Shell-script"
@@ -1605,7 +1599,13 @@ with your script for an edit-interpret-debug cycle."
nil nil
((?/ . "w") (?~ . "w") (?. . "w") (?- . "w") (?_ . "w")) nil
(font-lock-syntactic-face-function
- . ,#'sh-font-lock-syntactic-face-function))))
+ . ,#'sh-font-lock-syntactic-face-function)))
+ ;; Parse or insert magic number for exec, and set all variables depending
+ ;; on the shell thus determined.
+ (sh-set-shell (sh--guess-shell) nil nil)
+ (add-hook 'flymake-diagnostic-functions #'sh-shellcheck-flymake nil t)
+ (add-hook 'hack-local-variables-hook
+ #'sh-after-hack-local-variables nil t))
;;;###autoload
(defalias 'shell-script-mode 'sh-mode)
@@ -1617,6 +1617,10 @@ This mode automatically falls back to `sh-mode' if the buffer is
not written in Bash or sh."
:syntax-table sh-mode-syntax-table
(when (treesit-ready-p 'bash)
+ (sh-set-shell "bash" nil nil)
+ (add-hook 'flymake-diagnostic-functions #'sh-shellcheck-flymake nil t)
+ (add-hook 'hack-local-variables-hook
+ #'sh-after-hack-local-variables nil t)
(treesit-parser-create 'bash)
(setq-local treesit-font-lock-feature-list
'(( comment function)
diff --git a/lisp/subr.el b/lisp/subr.el
index a7a67c570b6..427014cedc3 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -7173,12 +7173,13 @@ CONDITION is either:
(funcall match (list condition))))
(defun match-buffers (condition &optional buffers arg)
- "Return a list of buffers that match CONDITION.
-See `buffer-match-p' for details on CONDITION. By default all
-buffers are checked, this can be restricted by passing an
-optional argument BUFFERS, set to a list of buffers to check.
-ARG is passed to `buffer-match', for predicate conditions in
-CONDITION."
+ "Return a list of buffers that match CONDITION, or nil if none match.
+See `buffer-match-p' for various supported CONDITIONs.
+By default all buffers are checked, but the optional
+argument BUFFERS can restrict that: its value should be
+an explicit list of buffers to check.
+Optional argument ARG is passed to `buffer-match-p', for
+predicate conditions in CONDITION."
(let (bufs)
(dolist (buf (or buffers (buffer-list)))
(when (buffer-match-p condition (get-buffer buf) arg)