* etc/NEWS: Add entry for lua-ts-mode changes.
* lisp/progmodes/lua-ts-mode.el
(lua-ts-auto-close-block-comments): New user option.
(lua-ts-mode): Add '--[[ ]]' pairs to 'electric-pair-pairs' only
if 'lua-ts-auto-close-block-comments' is non-nil.
* lisp/textmodes/texinfo.el (texinfo-mode): Add "`` ''" pairs to
'electric-pair-pairs'.
* test/lisp/progmodes/lua-ts-mode-tests.el
(lua-ts-test-auto-close-block-comments): Add new test.
(Bug#79047)
Currently a condition can only be a regexp or a major-mode symbol but
there's no real reason to not allow any predicate as a condition.
* doc/misc/autotype.texi: Document the new condition type in
'auto-insert-alist'.
* etc/NEWS: Announce the new condition type in 'auto-insert-alist'.
* lisp/autoinsert.el (auto-insert-alist): Add the new condition type to
the variable documentation.
(auto-insert): Change the way the condition is matched to allow for
custom predicates.
* test/lisp/autoinsert-tests.el
(autoinsert-tests-auto-insert-lambda/-nil): Add two tests for
lambdas (nil and t cases)
(autoinsert-tests-auto-insert-predicate/-nil): Add two tests for named
predicates (nil and t cases) (Bug#79178)
* lisp/vc/vc.el (vc-move-working-tree): Check entries in
vc-dir-buffers for liveness. Don't hardcode "*vc-dir*"; instead
call uniquify-buffer-base-name. Call uniquify-rename-buffer,
not rename-buffer, so that the buffer is not marked unmanaged.
* lisp/emacs-lisp/easy-mmode.el (define-globalized-minor-mode)
<MODE-set-explicitly>: Make this an internal variable using '--'.
<MODE-major-mode>: Make this an internal variable using '--'.
Use the name of the global mode not the local mode (bug#79198).
* lisp/vc/vc.el (vc-add-working-tree, vc-move-working-tree):
Have project-remember-project move the new working trees to the
front of the list of projects. Suggested by Dmitry Gutov
<dmitry@gutov.dev>.
* lisp/progmodes/js.el (js-json-mode): Now that we don't inherit
from `js-mode` any more, we can't rely on the heuristic to find
the indentation var, so we need to.set
`editorconfig-indent-size-vars` explicitly.
* lisp/progmodes/project.el (project--remember-dir)
(project-remember-project): New STABLE argument.
* lisp/vc/vc.el (vc-add-working-tree)
(vc--prompt-other-working-tree, vc-move-working-tree): Use it.
* lisp/progmodes/project.el
(project-find-matching-buffer-function): New variable.
(project-find-matching-file): Delete.
(dired-current-directory): Declare.
(project-find-matching-file-or-directory): New function. Like
the old 'project-find-matching-file', but also handle Dired
buffers (bug#79126). When matching file/directory does not
exist, try going up in the directory tree until we find
something that does.
(project-find-matching-buffer): New command.
* lisp/vc/vc.el (vc-switch-working-tree): Use it (bug#79126).
* etc/NEWS: Announce new command and new variable.
* lisp/help.el (help-function-arglist): Fix use of `documentation`,
to obey the `function-documentation` property.
* test/lisp/help-tests.el (help-tests--use-docstring-arglist-79128):
New test.
* test/lisp/eshell/em-script-tests.el
(em-script-test/batch-file/shebang): "env -S" is not supported.
* test/src/fns-tests.el (fns-tests-random): 'random' is
non-deterministic on OpenBSD. (Bug#79190)
Currently a condition can only be a regexp or a major-mode symbol
but there's no real reason to not allow any predicate as a
condition.
* doc/misc/autotype.texi: Document the new condition type in
'auto-insert-alist'.
* etc/NEWS: Announce the new condition type in 'auto-insert-alist'.
* lisp/autoinsert.el (auto-insert-alist): Add the new condition
type to the variable documentation.
(auto-insert): Change the way the condition is matched to allow for
custom predicates. (Bug#79178)
Bug#78967.
(calendar-mode): Init new variables with user options.
* lisp/calendar/calendar.el (calendar-generate-window)
(calendar-unmark):
* lisp/calendar/diary-lib.el (diary-mark-entries)
(diary-redraw-calendar):
* lisp/calendar/holidays.el (calendar-mark-holidays): Use new
variables.
* etc/NEWS: Document the change.
* src/eval.c: new primitive debugger-trap
* src/.gdbinit: set breakpoint to Fdebugger_trap
* etc/DEBUG: document it.
Remove suggestion to use Fredraw_display.
This do-nothing primitive gives control to GDB, and for debugging
convenience a breakpoint is set by default in .gdbinit.
* lisp/progmodes/python.el (python-shell-local-prefix): New
constant.
(python-shell--convert-file-name-to-send): New function to
add/remove prefix.
(python-shell-send-string, python-shell-send-file): Changed to
use 'python-shell--convert-file-name-to-send'.
(python-pdbtrack-set-tracked-buffer): Changed to add/remove
prefix.
* test/lisp/progmodes/python-tests.el
(python-shell--convert-file-name-to-send-1): New test.
(Bug#79036)
* lisp/net/tramp-adb.el (tramp-adb-handle-set-file-times):
Don't use UTC in all cases.
* lisp/net/tramp-smb.el (tramp-smb-handle-set-file-times): New defun.
(tramp-smb-file-name-handler-alist): Use it.
* test/lisp/net/tramp-tests.el (tramp-test22-file-times): Adapt test.
* lisp/external-completion.el: Require 26.1 (picked out of thin air).
(external-completion-table): Undo use of the hash-table-contains-p,
recently introduced.
* lisp/progmodes/project.el (project-shell, project-eshell):
When a numeric prefix is supplied, the command switches to or
creates a session buffer whose name has that number as a suffix.
For instance, C-2 yields "*name-of-project-shell<2>*". As
before, a plain universal argument C-u creates a new session
with an automatically generated numeric suffix. This change
makes the behavior of the project-shell commands consistent with
how M-x eshell handles numeric prefixes.
* etc/NEWS: Announce the change. (bug#76500)
* src/xfns.c (x_set_tool_bar_lines, x_change_tool_bar_height)
* src/pgtkfns.c (x_change_tool_bar_height)
(pgtk_set_tool_bar_lines): Set f->tool_bar_resized to true so
inhibiting implied resizing works for frames without initial
tool bar too. See the thread
https://lists.gnu.org/archive/html/emacs-devel/2025-08/msg00034.html.
* lisp/vc/vc-annotate.el (vc-annotate--file-name-change):
New function (bug#26345).
(vc-annotate-warp-revision): Use it here.
Co-Authored-By: Jakub Ječmínek <kuba@kubajecminek.cz>
* lisp/progmodes/project.el (project-prompter)
(project-prompt-project-dir, project-prompt-project-name): New
PREDICATE and REQUIRE-KNOWN optional arguments.
* lisp/vc/vc.el (project-prompter): Declare.
(vc--prompt-other-working-tree): New function.
(vc-switch-working-tree, vc-delete-working-tree)
(vc-move-working-tree): Use it to prompt for the other working
tree in a way that respects 'project-prompter' (bug#79024).
* etc/NEWS: Announce all three optional arguments. Rework
description of new optional argument to 'project-current'.
* lisp/vc/vc-git.el (vc-git-known-other-working-trees):
* test/lisp/vc/vc-tests/vc-tests.el (vc-test--other-working-trees):
Tolerate directories with symlinks in them, such as the standard
temporary dirs on MacOS. 'git worktree list' outputs expanded names.