1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-17 03:21:51 -07:00
Commit graph

98760 commits

Author SHA1 Message Date
Helmut Eller
146a2d4faf Simplify igc--format-bytes-human-readable
Suggested by Pip Cet.

* lisp/emacs-lisp/igc.el (igc--format-bytes-human-readable): Use
file-size-human-readable.
2025-10-04 20:54:19 +02:00
Helmut Eller
f9f8ffbb00 Add a igc-describe-arena command
* src/igc.c (Figc__describe_arena): New wrapper for ArenaDescribe.
(syms_of_igc): Register it.
* lisp/emacs-lisp/igc.el (igc-describe-arena): New command.
2025-10-04 17:33:10 +02:00
Helmut Eller
98e1b11f16 Merge branch 'master' into feature/igc 2025-10-04 16:41:45 +02:00
Helmut Eller
c5f80fa076 Minor optimization
* lisp/emacs-lisp/igc.el (igc--format-bytes-human-readable): Avoid some
consing.
2025-10-04 16:40:01 +02:00
Eli Zaretskii
5ee1e205e1 ; Improve the documentation of the last commit
* lisp/vc/log-view.el (log-view-copy-revision-as-kill):
* doc/emacs/maintaining.texi (VC Change Log):
* etc/NEWS: Improve wording of last commit.  (Bug#79493)
2025-10-04 17:18:12 +03:00
Sean Whitton
d0c63b8427 Improve log-view-copy-revision-as-kill
* lisp/vc/log-view.el (log-view-copy-revision-as-kill): Signal
user-error if there is no revision at point.
* doc/emacs/maintaining.texi (VC Change Log):
* etc/NEWS: Shorten docs for the new command.
2025-10-04 14:41:16 +01:00
Timo Myyrä
2ce33b66c5 New command log-view-copy-revision-as-kill
* lisp/vc/log-view.el (log-view-copy-revision-as-kill): New
command.
(log-view-mode-map): Bind it.
* doc/emacs/maintaining.texi (VC Change Log):
* etc/NEWS: Document it.
2025-10-04 14:40:03 +01:00
Elías Gabriel Pérez
3271d9fc96 hideshow.el: Minor optimizations
* lisp/progmodes/hideshow.el (hs-hideable-region-p): New
function.
(hs--make-indicators-overlays, hs--add-indicators)
(hs-hide-block-at-point, hs-hide-all, hs-hide-block)
(hs-hide-initial-comment-block): Use it.  (Bug#79533)
2025-10-04 11:27:27 +03:00
Augusto Stoffel
b8555ebff4 Add 'auto-mode-alist' entry for Containerfile
* lisp/progmodes/dockerfile-ts-mode.el: Also match Containerfile
and Containerfile.* in the 'auto-mode-alist' entry.  (Bug#79524)
2025-10-04 11:16:37 +03:00
Jeremy Bryant
1b3a8a0099 * lisp/emacs-lisp/igc.el: Add docstrings in stats export functions
(igc--collect-stats-csv, igc--collect-stats-sqlite): Add docstrings.
(Bug#79564)
2025-10-04 10:21:45 +03:00
Stefan Monnier
6a12fe3d79 (editorconfig-indentation-alist): Pare down
* lisp/editorconfig.el (editorconfig-indentation-alist): Remove entries
of the form `(MODE-mode MODE-basic-offset)`, `(MODE-mode
MODE-indent-level)`, or `(MODE-mode MODE-indent-offset)` since they are
covered by the fallback guessing code.
(editorconfig--default-indent-size-function): Remove "-block-offset"
from the guessing code since it's used only by `octave-mode`.
2025-10-03 17:17:02 -04:00
Sean Whitton
9deff2926b New command log-view-unmark-all-entries
* lisp/vc/log-view.el (log-view-unmark-all-entries): New
command.
(log-view-mode-map): Bind it.
* doc/emacs/maintaining.texi (VC Change Log):
* etc/NEWS: Document it.
2025-10-03 20:54:25 +01:00
Sean Whitton
d5faebe8db Merge from origin/emacs-30
6a8fda1f33 Fix process name matching in 'tramp-process-running-p'
217fd4f09e ; * doc/lispref/modes.texi (Defining Minor Modes): Fix la...
2025-10-03 20:51:18 +01:00
Helmut Eller
28cfce1da5 Optionally display sizes in human readable format
* lisp/emacs-lisp/igc.el (igc--number-format): New variable.
(igc--format-bytes-human-readable, igc--format-bytes,
igc--format-bytes-cell, igc--format-avg-cell):
(igc--insert-info): Use them
(igc-cycle-number-format): New command.
(igc-stats-mode): Bind it to n.
2025-10-03 20:47:28 +02:00
Helmut Eller
498f306ca6 Display igc-stats more compactly
* lisp/emacs-lisp/igc.el (igc--insert-info-row)
(igc--compute-column-widths, igc--format-cell): New helpers
(igc-stats): Use them.
2025-10-03 17:45:08 +02:00
Sean Whitton
0134d4c4fd vc--prompt-other-working-tree: Better handle no other working trees
* lisp/vc/vc.el (vc--prompt-other-working-tree): If there are no
other working trees but ALLOW-EMPTY is non-nil, it is not an
error.
2025-10-03 15:32:44 +01:00
Spencer Baugh
3ec87212a4 Eglot: make markup invisible instead of deleting it (bug#79552)
We use gfm-view-mode to render Markdown before we hand over the string
to ElDoc (which usually put it in a 'special' mode "*eldoc*" buffer).
'gfm-view-mode' adds keymap text properties to make links clickable.  It
also makes some of the markup invisible with a special 'invisible'
property value which is specific to 'gfm-view-mode'.  We used to delete
the latter, therefore breaking the link-clicking.  Simply resetting the
regions with non-nil 'invisible' to 't' instead of deleting them fixes
this.  See also https://github.com/joaotavora/eglot/discussions/1238

* lisp/progmodes/eglot.el: Make invisible markup invisible
instead of deleting it.

* etc/EGLOT-NEWS: Mention bugfix.

Co-authored-by: João Távora <joaotavora@gmail.com>
2025-10-03 09:44:56 +01:00
Sean Whitton
72f3f48d36 Log View marking: Fix lambda lists
* lisp/vc/log-view.el (log-view-mark-entry)
(log-view-unmark-entry): Mark ARG as a required argument, as it
in fact is.
(log-view-toggle-mark-entry): Call them properly.
2025-10-02 21:18:51 +01:00
Sean Whitton
b38e54b667 ; * lisp/vc/vc.el (vc-print-root-log): Use plusp. 2025-10-02 20:20:14 +01:00
Eli Zaretskii
cf68270b89 * lisp/term/w32-nt.el (dynamic-library-alist): Add libxml2-16.dll.
Reported by Andy Moreton <andrewjmoreton@gmail.com>.
2025-10-02 15:38:06 +03:00
Sean Whitton
b5cf0786a2 New command vc-kill-other-working-tree-buffers
* lisp/vc/vc.el (vc-kill-other-working-tree-buffers): New
command.
* lisp/vc/vc-hooks.el (vc-prefix-map): Bind it.
* doc/emacs/vc1-xtra.texi (Other Working Trees):
* etc/NEWS: Document it.
2025-10-01 20:51:57 +01:00
Renato Ferreira
6a8fda1f33 Fix process name matching in 'tramp-process-running-p'
* lisp/net/tramp.el (tramp-process-running-p): Use 'compare-strings'
for matching PROCESS-NAME with process command.  (Bug#79545)

Copyright-paperwork-exempt: yes
2025-10-01 12:44:33 +02:00
Sean Whitton
889ae269b0 ; project-prompt-project-name: Fix pcase usage. 2025-10-01 11:27:25 +01:00
Sean Whitton
c24e173c9c vc-add-working-tree: Finish by starting Dired
There won't be any uncommitted changes in the new working tree
yet, so vc-dir is unlikely to be useful.

* lisp/vc/vc.el (vc-add-working-tree): Finish by calling 'dired'
not 'vc-dir'.
* test/lisp/vc/vc-tests/vc-tests.el
(vc-test--other-working-trees): Delete stubbing out 'vc-dir'.
2025-10-01 11:26:18 +01:00
Juri Linkov
b5ea92a62b * lisp/hl-line.el (global-hl-line-buffers): Skip internal buffers (bug#79547). 2025-10-01 09:40:05 +03:00
Sean Whitton
6ef6b517aa VC: Allow deleting or moving current working tree
* lisp/progmodes/project.el (project-prompter)
(project-prompt-project-dir, project-prompt-project-name):
* lisp/vc/vc.el (vc--prompt-other-working-tree): New ALLOW-EMPTY
optional argument.
(delete-working-tree, move-working-tree): Specify that callers
must ensure DIRECTORY is not the current working tree.
(vc-delete-working-tree, vc-move-working-tree): Pass ALLOW-EMPTY
non-nil to vc--prompt-other-working-tree.  Bind
'default-directory' to another working tree when operating on
the current working tree.
(vc-delete-working-tree): Extra prompt when asked to delete the
current working tree.  When deleting the current working tree,
call 'bury-buffer' one or more times at the end.
2025-09-30 16:12:14 +01:00
Juri Linkov
40a22ced14 New value 'window' of 'global-hl-line-sticky-flag'
* etc/NEWS: Rename 'global-hl-line-modes' to 'global-hl-line-buffers'
(bug#79481).  Mention new default value of 'global-hl-line-buffers'
(bug#64993).  Mention new value 'window' of 'global-hl-line-sticky-flag'
that is more useful than the value 'all' now removed from NEWS (bug#64993).

* lisp/hl-line.el (hl-line-nonselected): New face.
(global-hl-line-sticky-flag): Add the value 'window'.
(global-hl-line-buffers): Change the default value to exclude
the minibuffer and 'cursor-face-highlight-mode'.
(global-hl-line-mode): Handle the value 'window' of
'global-hl-line-sticky-flag'.
(global-hl-line-window-redisplay): New function.
2025-09-29 20:47:50 +03:00
Juri Linkov
aaf8b301e7 Fix completions truncated on scrolling (bug#79506)
* lisp/simple.el (completion-setup-function):
Add 'completion--lazy-insert-strings-on-scroll'
to buffer-local hook 'window-scroll-functions'.

* lisp/minibuffer.el (completion--lazy-insert-strings-on-scroll):
New function.
(completion--in-region-1): Remove calls to the function
'completion--lazy-insert-strings' that now are handled
by the scroll hook.
2025-09-29 20:13:05 +03:00
Eli Zaretskii
98b2516f6e Fix 'mm-copy-to-buffer' when original text is multibyte
* lisp/gnus/mm-decode.el (mm-copy-to-buffer): Always return a
unibyte buffer.  If the original text was multibyte, encode it
while inserting it into the copy buffer.  (Bug#79376)
2025-09-29 15:13:49 +03:00
Robert Pluim
6992d0e3bb ; Fix typos
* lisp/mail/mail-utils.el (mail-fetch-field, mail-mbox-from):
'headers', not 'header'.
2025-09-29 11:26:53 +02:00
Liu Hui
52ed675063 Fix etags-regen-mode for remote projects (bug#79358)
* lisp/progmodes/etags-regen.el
(etags-regen--process-file-region): New function.
(etags-regen--tags-generate, etags-regen--append-tags): Use the
new helper function to run the program, and use relative file
name if TAGS file is in the project root.
(etags-regen--update-file): Use relative file name if possible.
2025-09-29 02:40:28 +03:00
Eli Zaretskii
38c658de7d Make textsec descriptive texts more user-friendly
* lisp/international/textsec.el (textsec-domain-suspicious-p)
(textsec-local-address-suspicious-p, textsec-name-suspicious-p)
(textsec-suspicious-nonspacing-p): Clarify descriptive texts.
2025-09-28 15:35:17 +03:00
Eli Zaretskii
3f230d8465 Detect suspicious email addresses in Rmail and Sendmail
* lisp/mail/rmail.el (rmail-detect-suspicious-headers): New user
option.
(rmail-check-suspicious-from): New function, highlights suspicious
"From" addresses.
(rmail-show-message-1): Call 'rmail-check-suspicious-from' if
'rmail-detect-suspicious-headers' is non-nil.
* lisp/mail/sendmail.el (mail-send): Detect suspicious addresses
before sending.

* etc/NEWS: Announce the new features.
2025-09-28 14:35:46 +03:00
Eli Zaretskii
ae4878c53b Revert "Fix bug#79518 with 'windmove-mode' in "C-h m" display"
This reverts commit bf750adc4e.
It caused windmove to be loaded unconditionally.
The correct "fix" for bug#79518 is to load the package or
to toggle the mode.
2025-09-28 08:19:48 +03:00
Stefan Monnier
b9573f8f1a peg.el: Fix bug#79502 a bit more
* lisp/progmodes/peg.el (peg--detect-cycles): Accept args.
(peg--detect-cycles) <funcall>: New method.
2025-09-27 22:57:02 -04:00
Stefan Monnier
021b7065bb peg.el: Fix bug#79502
* lisp/progmodes/peg.el (peg--merge-error): Provide a default method.
(peg--merge-error) <call>: Handle calls with arguments.
(peg--merge-error) <any, not>: Remove methods, now redundant with the
default method.
(peg--merge-error) <guard>: Delegate to the default method if we can't
do better.
2025-09-27 18:20:37 -04:00
Sean Whitton
4e7cb37b84 VC prepare-patch: New :patch-start & :patch-end plist entries
* lisp/vc/vc.el (prepare-patch): Specify :patch-start and
:patch-end plist entries.
* lisp/vc/vc-git.el (vc-git-prepare-patch): Use -n1 to avoid
passing a revision range to git-format-patch, which is a bit
simpler.  Catch search-failed errors and signal an error with a
more helpful message.  Properly handle Subject: header by
looking for continuation lines.  Return :patch-start and
:patch-end entries in the plist.
* lisp/vc/vc-hg.el (vc-hg-prepare-patch): Always pass --git to
'hg export' for consistency.  Catch search-failed errors and
signal an error with a more helpful message.  Return a
:patch-start entry in the plist.
2025-09-27 21:36:51 +01:00
Juri Linkov
3cdc615218 Improve documentation and customization of 'derived-mode' in buffer predicate
* doc/lispref/buffers.texi (Buffer List):
* lisp/subr.el (buffer-match-p):
Document that 'derived-mode' can be a list (bug#79481).

* lisp/wid-edit.el (buffer-predicate): Support a list for 'derived-mode'.
2025-09-27 20:56:54 +03:00
Eshel Yaron
32b9902603
; (read-string-from-buffer): Fix thinko and typo. 2025-09-27 16:00:41 +02:00
Martin Rudalics
b60e0f4294 Restore mouse line dragging in character increments (Bug#79351)
* lisp/mouse.el (mouse-drag-line): Restore dragging in character
increments and make it the default (Bug#79351).
* etc/NEWS: Mention restored behavior of mouse line dragging.
2025-09-27 10:07:14 +02:00
Sean Whitton
6eaa1d279b ; * lisp/vc/vc-git.el (vc-git-cherry-pick-comment): Fix logic. 2025-09-26 17:25:07 +01:00
Jakub Ječmínek
d3333cb1b2 nnmbox-read-mbox: fix Xref header parsing
* lisp/gnus/nnmbox.el (nnmbox-read-mbox): Use the 'mail-fetch-field'
function instead of a broken regexp which matched Date-like headers.

(Bug#79167)
2025-09-26 16:03:11 +02:00
Eli Zaretskii
bf750adc4e Fix bug#79518 with 'windmove-mode' in "C-h m" display
* lisp/windmove.el (windmove-mode): Make sure "C-h m" mentions it.
2025-09-26 14:55:34 +03:00
Eli Zaretskii
0fe5113fa3 Fix dunnet when played on terminals which don't support UTF-8
* lisp/play/dunnet.el (dun-rooms, dun-endgame-question, dun-help)
(dun-physobj-desc, dun-endgame-questions): Don't use non-ASCII
characters.  (Bug#79520)
2025-09-26 14:24:00 +03:00
Stefan Monnier
fa8e32f757 (dabbrev-completion): Try and fix the test regressions
* lisp/dabbrev.el (dabbrev-completion): Revert this part of last
change, but additionally set `dabbrev--last-abbrev-location` so we know
what the vars were reset for.
(dabbrev-capf): Be more careful about when and how to reset the vars.
(dabbrev--abbrev-at-point): Don't set `dabbrev--last-abbrev-location`,
so it doesn't mess with the marker we set it to in
`dabbrev-capf` or `dabbrev-completion`.
2025-09-25 15:24:53 -04:00
Elías Gabriel Pérez
06d87e44cb (electric-indent-actions): Add missing NEWS
* lisp/electric.el (electric-indent-actions): Fix docstring.
2025-09-25 13:40:27 -04:00
Sean Whitton
9a86a093bc vc-git--checkin: Ignore 'git apply --3way' exiting 1
This is expected to happen in some cases.

* lisp/vc/vc-git.el (vc-git--with-apply-temp): New OKSTATUS
parameter.
(vc-git--checkin): Use it to ignore 'git apply --3way' exiting
1.
2025-09-25 18:19:38 +01:00
Eli Zaretskii
69ac58b5d2 ; Avoid byte-compiler warnings in python.el
* lisp/progmodes/python.el (treesit-node-prev-sibling)
(treesit-node-field-name-for-child): Declare.
2025-09-25 20:06:12 +03:00
Sean Whitton
b2e35d1d2c vc-git--checkin: Avoid passing --ours to git-apply
* lisp/vc/vc-git.el (vc-git--with-apply-temp): New BUFFER param.
(vc-git--checkin): Avoid passing --ours to git-apply.
2025-09-25 17:44:30 +01:00
Juri Linkov
e719f62a50 * lisp/minibuffer.el (minibuffer--nonselected-check): Simplify condition. 2025-09-25 09:50:39 +03:00