1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-24 19:03:29 +00:00
Commit Graph

167419 Commits

Author SHA1 Message Date
Po Lu
2baf2c5fd9 Merge remote-tracking branch 'origin/master' into feature/android 2023-07-02 08:26:54 +08:00
Harald Jörg
9b9dcc146b ; cperl-mode.el: Fix two indentation bugs (Bug#11733)
* lisp/progmodes/cperl-mode.el (cperl-sniff-for-indent): Detect
whether we have a label or a regex/string.
(cperl-calculate-indent): Check for things which look like labels
but aren't.

* test/lisp/progmodes/cperl-mode-tests.el (cperl-test-bug-11733):
Test the examples provided in the bug report.

* test/lisp/progmodes/cperl-mode-resources/cperl-bug-11733.pl:
Examples from the bug report.
2023-07-02 00:37:10 +02:00
João Távora
a371e1def7 Eglot: fix broken indentation of eglot--sig-info
* lisp/progmodes/eglot.el (eglot--sig-info): Fix.
2023-07-01 22:49:49 +01:00
João Távora
f6e6d6c730 Eglot: bail out of eglot-imenu if no server capability (bug#64274)
* lisp/progmodes/eglot.el (eglot-imenu): Bail out if no
capability.
2023-07-01 22:49:49 +01:00
João Távora
03d4ca6f6b Eglot: improve heuristic to highlight function names in signatures
* lisp/progmodes/eglot.el (eglot--sig-info): Rework.

See https://github.com/joaotavora/eglot/discussions/1251.
2023-07-01 22:49:48 +01:00
Harald Jörg
ce8e6cea42 cperl-mode.el: Support Perl 5.38 syntax for subroutine signatures
* lisp/progmodes/cperl-mode.el (defconst): New rx sequence
describing a signature with initialization.
(cperl-init-faces): integrate the new rx sequence into the
font-lock-defaults init routine (Bug#64190) (Bug#64364).

* test/lisp/progmodes/cperl-mode-resources/cperl-bug-64364.pl: Add
test data for a signature with initialization (tests indentation).

* test/lisp/progmodes/cperl-mode-resources/proto-and-attrs.pl: Add
test data for a signature with initialization (tests fontification).
2023-07-01 21:40:46 +02:00
Jim Porter
75278855f4 Document optional Eshell modules
* lisp/eshell/em-rebind.el (eshell-rebind): Correct/reword docstring.

* doc/misc/eshell.texi (Built-ins): Move disabled-by-default commands
to...
(Tramp extensions, Extra built-in commands): ...here
(Optional modules, Key rebinding, Smart scrolling): Add documentation.
(Bug and ideas): Documentation is no longer incomplete!
2023-07-01 12:03:56 -07:00
Jim Porter
77f13edab0 Correct the Eshell documentation about how to write new modules
* doc/misc/eshell.texi (Writing a module): Fix the documentation.
'eshell-defgroup' doesn't exist anymore.
2023-07-01 12:03:56 -07:00
Jim Porter
f2981a1681 Restructure Eshell extension modules documentation
This adds a section for documenting all the optional modules.

* doc/misc/eshell.texi (Extension modules): Move explanation about
writing modules to...
(Writing a module): ... here.
(Module testing): Remove.  Testing an Eshell module doesn't require
any special documentation.
(Key binding, Smart scrolling, Electric forward slash): Move under...
(Optional modules): ... here.
(Directory handling, Terminal emulation): Remove.  These modules are
enabled by default, and so are documented above.
(Tramp extensions, Extra built-in commands): New sections.
2023-07-01 12:03:56 -07:00
Jim Porter
194de36ca9 ; * doc/misc/eshell.texi (Bugs and ideas): Remove implemented feature. 2023-07-01 12:03:56 -07:00
F. Jason Park
6ce957154b Redo erc-nickname-in-use-functions as a local module
* etc/ERC-NEWS: Mention new module `services-regain'.
* lisp/erc/erc-backend.el: Rename option.
* lisp/erc/erc-services.el (erc-services-regain-alist): Strategies for
regaining a lost nickname on reconnect.  This option, in addition to
the rest of these changes, is a redo of
`erc-nickname-in-use-functions' from commit 8c0c9826 "Add hook to
regain nickname in ERC", which originally stemmed from bug#62044.
(erc-services-retry-nick-on-connect, erc-services-issue-regain,
erc-services-issue-ghost-and-retry-nick): New function variants for
`erc-services-regain-alist.
(erc-services-regain-mode, erc-services-regain-enable,
erc-services-regain-disable): New local module to activate
nick-regaining behavior.
(erc--nickname-in-use-make-request): New method, a services-specific
implementation.
* lisp/erc/erc.el (erc--nickname-in-use-make-request): New generic
function to request alternate nick when first choice is rejected.
(erc-nickname-in-use): Call `erc--nickname-in-use-make-request' to
request alternate nick.
* test/lisp/erc/erc-scenarios-services-misc.el
(erc-scenarios-services-misc--reconnect-retry-nick): Adopt renamed
version of `erc-scenarios-base-renick-auto-regain'.
(erc-scenarios-services-misc--regain-command,
erc-scenarios-services-misc--ghost-and-retry-nick): New tests.
* test/lisp/erc/resources/services/regain/reconnect-retry-again.eld:
New test data file reusing existing blob c0529052 that once lived at
resources/base/renick/regain/normal-again.eld.
* test/lisp/erc/resources/services/regain/reconnect-retry.eld: New
test data file reusing existing blob 9f4df70e5 that once lived at
resources/base/renick/regain/normal.eld.
* test/lisp/erc/resources/services/regain/taken-ghost.eld: New test
data file.
* test/lisp/erc/resources/services/regain/taken-regain.eld New test
data file.
2023-07-01 07:21:30 -07:00
F. Jason Park
99d74dcd45 Account for leading timestamps in erc-match
* lisp/erc/erc-match.el (erc-text-matched-hook): Mention that stamps
may be present in the narrowed buffer but absent from the message
parameter.
(erc-match--message): New function containing what was the body of
`erc-match-message' as if the latter were simply renamed.
(erc-match-message): Move body to `erc-match--message' and call it
with more aggressive narrowing.  This fixes a regression stemming from
d880a08f "Cement ordering of essential hook members in ERC".  Special
thanks to Libera.Chat user jrm for reporting this bug.  (Bug#60936)
* test/lisp/erc/erc-scenarios-match.el: New test file.
2023-07-01 07:19:51 -07:00
Harald Jörg
d42b45dcc7 cperl-mode: Fix byte-compilation warnings
* lisp/progmodes/cperl-mode.el (defconst): Reformat docstring to
fit into 80 columns.
(cperl-find-sub-attrs): Mark lexical parameters as unused.

* test/lisp/progmodes/cperl-mode-tests.el
(cperl-test-fontify-attrs-and-signatures): Fix use of
`match-beginning'
(perl-indent-parens-as-block): Define as a variable.
2023-07-01 15:25:33 +02:00
Mattias Engdegård
2195935870 Add duplicate-region-final-position (bug#64185)
* lisp/misc.el (duplicate-region-final-position): New defcustom.
(duplicate-dwim): Use it.
* lisp/rect.el (rectangle--duplicate-right): Add displacement
argument.
* test/lisp/misc-tests.el (misc--duplicate-dwim): Extend test.
2023-07-01 12:41:09 +02:00
Eli Zaretskii
3ba9f9657f Merge from origin/emacs-29
edd36786e1 ; * lisp/bookmark.el (bookmark-bmenu-locate): Doc fix (bu...
16eac20a5d ; Fix last change
ab8d0f7b76 Add project command entries to the menu-bar
fc6099bf04 ; Improve documentation of text-property-search-* functions
cc660bd265 ; * etc/PROBLEMS: Mention MinGW problems with -D_FORTIFY_...
a5bd9fb8c4 ; Improve doc strings in register.el
0be18d8097 ; Fix @xref in last change to doc/emacs/regs.texi.
624c779517 ; Fix tree-sitter C binding typos in Elisp manual.
16e9bdff4f Improve documentation of registers
2023-07-01 06:30:00 -04:00
Eli Zaretskii
d0eeb4c5cd ; Merge from origin/emacs-29
The following commit was skipped:

884b668b98 Use a temporary buffer in nnagent-request-set-mark (bug#6...
2023-07-01 06:30:00 -04:00
Eli Zaretskii
fbdc85b8f8 Merge from origin/emacs-29
a722e7dd15 Merge branch 'emacs-29' of git.savannah.gnu.org:/srv/git/...
65f146cf1c ; * lisp/calculator.el (calculator-need-3-lines): Fix las...
9e8386bdac Support cons cell as value of ':line-width' box attribute
1d2ba6b363 ; * admin/notes/tree-sitter/treesit_record_change: Update.
02b6be892f Add missing calls to treesit_record_change in editfns.c
e982192e93 Call treesit_record_change in subst-char-in-region (bug#6...
ddbb11f565 ; * lisp/misc.el (duplicate-line-final-position): Fix las...
cecbe92d5d ; * lisp/misc.el (duplicate-line-final-position): doc pre...
042f0d6a14 ; Fix documentation of ':box' face attribute

# Conflicts:
#	etc/NEWS
2023-07-01 06:29:52 -04:00
Eli Zaretskii
3d65afd7b7 ; Merge from origin/emacs-29
The following commit was skipped:

d5cff340b3 * lisp/misc.el (duplicate-line-final-position): New defcu...
2023-07-01 06:29:44 -04:00
Eli Zaretskii
0006245f1d Merge from origin/emacs-29
ef16339918 Make js-beginning-of-defun return non-nil on success
2c90ade09a Tree-sitter use with-silent-modifications like jit-lock (...
11cead0d73 Fix todo-mode.el Commentary and a doc string (bug#64298)
6ae83322d4 Prevent truncation of todo-mode categories sexp
ee41f07be5 Avoid making todo-mode buffers manually editable
53332bdf62 ; * doc/lispref/variables.texi: Fix define-obsolete-varia...
162c9c058e ; Document that 'named-let' needs lexical-binding
68028f0fa3 ; * etc/PROBLEMS: Fix typo.
2023-07-01 06:29:43 -04:00
Eli Zaretskii
e275e63eed ; Merge from origin/emacs-29
The following commit was skipped:

ac0a82ea98 Fix Tramp mount-spec (don't merge)
2023-07-01 06:29:43 -04:00
Eli Zaretskii
e45ddf2fdc Merge from origin/emacs-29
4df510c7a7 Fix VC package build when doc file isn't in a subdir
382f5fa813 ; * doc/emacs/package.texi (Fetching Package Sources): Fi...
fc7e7c3fde Fix type check in tramp-get-buffer-string
2aa57fe6cf ; Fix typo in maintaining.texi (bug#64279)
2023-07-01 06:29:43 -04:00
Eli Zaretskii
0bdd770762 ; Merge from origin/emacs-29
The following commits were skipped:

1d9200d9bb ; * doc/lispintro/emacs-lisp-intro.texi (car & cdr): Fix ...
987b25d60d Clarify list terminology
2023-07-01 06:29:43 -04:00
Eli Zaretskii
edd36786e1 ; * lisp/bookmark.el (bookmark-bmenu-locate): Doc fix (bug#64370). 2023-07-01 12:46:37 +03:00
Eli Zaretskii
16eac20a5d ; Fix last change
* lisp/menu-bar.el (menu-bar-file-menu, menu-bar-search-menu)
(menu-bar-replace-menu, menu-bar-project-menu)
(menu-bar-buffers-menu-command-entries): Fix help-echo text (bug#63469).
2023-07-01 12:43:33 +03:00
Spencer Baugh
ab8d0f7b76 Add project command entries to the menu-bar
This will make it easier for new users to learn these increasingly
important and useful commands.  (Bug#63469)

* lisp/menu-bar.el (menu-bar-file-menu): Add project-dired and
project-find-file entries.
(menu-bar-search-menu): Add project-find-regexp entry.
(menu-bar-replace-menu): Add project-query-replace regexp entry.
(menu-bar-shell-commands-menu): Add project-shell entry.
(menu-bar-buffers-menu-command-entries): Add project-switch-to-buffer
and project-list-buffer entries.
(menu-bar-project-menu): Add.
(menu-bar-tools-menu): Add "Project" submenu, and also project-compile
entry and change text for compile entry.
2023-07-01 12:33:24 +03:00
Eli Zaretskii
fc6099bf04 ; Improve documentation of text-property-search-* functions
* doc/lispref/text.texi (Property Search): Improve wording and markup.

* lisp/emacs-lisp/text-property-search.el (text-property-search-forward)
(text-property-search-backward): Doc fixes.  (Bug#64367)
2023-07-01 12:28:33 +03:00
Eli Zaretskii
8c7f92f25c Fix total count of messages in Rmail summary buffers
* lisp/mail/rmailsum.el (rmail-new-summary-1): Actually count the
messages in the summary buffer instead of relying on
'rmail-total-messages'.  Reported by Andrea Monaco
<andrea.monaco@autistici.org>.
2023-07-01 11:34:43 +03:00
Davide Masserut
bfec5674c6 Recognize PKGBUILD as bash style
* lisp/progmodes/sh-script.el (sh--guess-shell): Handle PKGBUILD.
(Bug#64251)
2023-07-01 11:27:58 +03:00
Michael Albinus
7bcf7b8e20 Improve Tramp for remote WebDAV
* lisp/net/tramp-gvfs.el (tramp-gvfs-do-copy-or-rename-file):
* lisp/net/tramp-rclone.el (tramp-rclone-do-copy-or-rename-file):
Improve stability for WebDAV.
2023-07-01 10:19:37 +02:00
Eli Zaretskii
cc660bd265 ; * etc/PROBLEMS: Mention MinGW problems with -D_FORTIFY_SOURCE=2. 2023-07-01 10:01:59 +03:00
Po Lu
3b75148a30 Merge remote-tracking branch 'origin/master' into feature/android 2023-07-01 08:33:13 +08:00
Harald Jörg
952692643e cperl-mode: Add recent features to etc/NEWS
I mishandled git and killed my previous commit.  Sorry for the noise.

* etc/NEWS: Add a section to Changes in Specialized Modes
2023-07-01 00:07:31 +02:00
Harald Jörg
61268e5827 cperl-mode: Add recent features to etc/NEWS
* etc/NEWS: Add a section to Changes in Specialized Modes
2023-06-30 23:58:31 +02:00
Harald Jörg
8956236635 cperl-mode: Add recent features to etc/NEWS
* etc/NEWS: Add a section to Changes in Specialized Modes
2023-06-30 23:57:51 +02:00
Harald Jörg
76182f4b93 ; cperl-mode-resources: More test cases for cperl-mode.el
* test/lisp/progmodes/cperl-mode-resources/proto-and-attrs.pl:
Adapt to the signatures now available in cperl-mode.el
2023-06-30 23:48:59 +02:00
Harald Jörg
a7ff8a76a5 cperl-mode.el: Support subroutine signatures
Since Perl 5.20, subroutine signatures were available as an
experimental feature.  With Perl 5.38, they will be always enabled in
the new object system.

* test/lisp/progmodes/cperl-mode-resources/cperl-bug-64190.pl:
* test/lisp/progmodes/cperl-mode-resources/cperl-bug-64364.pl: New
test resources.

* test/lisp/progmodes/cperl-mode-tests.el
(cperl-test-fontify-attrs-and-signatures): Add tests for
signatures.
(cperl-test-attribute-rx, cperl-test-attribute-list-rx)
(cperl-test-prototype-rx, cperl-test-signature-rx): Tests for the
new rx sequences.
(cperl-test-bug-64190): New test for multiline declarations.
(cperl-test-bug-64364): New test for indentation of declarations.

* lisp/progmodes/cperl-mode.el:
(toplevel): New rx sequences to match Perl variables and attributes.
(cperl-declaration-header-p): New function to identify declarations.
(cperl-block-declaration-p): Use the new function.
(cperl-mode): Use the rx sequences.
(cperl-get-state): Use the new function.
(cperl-sniff-for-indent): Use the new function.
(cperl-find-sub-attrs): Improve fontification of subroutine
prototypes and attributes while typing when jit-lock-mode is
active.  Detect signatures, and distinguish them from prototypes.
(cperl-find-pods-heres): Use the rx sequences to detect subroutines.
(cperl-init-faces): Use the rx sequences for fontification.
2023-06-30 23:41:06 +02:00
Eli Zaretskii
a5bd9fb8c4 ; Improve doc strings in register.el
* lisp/register.el (register-preview-delay)
(register-describe-oneline, register-preview-default)
(register-preview-function, register-preview, point-to-register)
(window-configuration-to-register)
(frame-configuration-to-register, jump-to-register)
(register-val-jump-to, number-to-register, increment-register)
(view-register, list-registers, register-val-describe)
(insert-register, register-val-insert, copy-to-register)
(append-to-register, prepend-to-register)
(copy-rectangle-to-register): Doc fixes.
2023-06-30 14:47:12 +03:00
Basil L. Contovounesios
0be18d8097 ; Fix @xref in last change to doc/emacs/regs.texi. 2023-06-30 12:21:00 +01:00
Basil L. Contovounesios
624c779517 ; Fix tree-sitter C binding typos in Elisp manual. 2023-06-30 12:04:42 +01:00
Po Lu
522c572075 * src/android.c (android_query_tree): Correctly return children. 2023-06-30 16:20:02 +08:00
Eli Zaretskii
16e9bdff4f Improve documentation of registers
* doc/lispref/text.texi (Registers): Document buffers in
registers.  Mention "frameset" as another name for "frame
configuration".
* doc/emacs/regs.texi (Registers, Configuration Registers)
(File and Buffer Registers): Clarify and improve wording.  Add
cross-references and indexing.
(Configuration Registers): Rename the section to a more accurate
name.  (Bug#64354)

* lisp/register.el (jump-to-register, point-to-register)
(register-alist, frame-configuration-to-register): Doc fixes.
(Bug#64353)
2023-06-30 10:13:53 +03:00
Andrew G Cohen
884b668b98 Use a temporary buffer in nnagent-request-set-mark (bug#64117)
Commit cb12a84f2c inadvertently removed
the use of a temporary buffer in nnagent-request-set-mark.  Bug and
fix reported by Jens Schmidt <jschmidt4gnu@vodafonemail.de>

* lisp/gnus/nnagent.el (nnagent-request-set-mark): Restore the use of
a temporary buffer that was inadvertently removed.

(cherry picked from commit 5075d75277)
2023-06-30 10:19:55 +08:00
Po Lu
714c425385 Merge remote-tracking branch 'origin/master' into feature/android 2023-06-30 08:36:53 +08:00
Yuan Fu
361bf8a113
Use OUT-DIR in treesit-install-language-grammar (bug#64295)
* lisp/treesit.el (treesit-install-language-grammar): Use out-dir.
2023-06-29 11:28:18 -07:00
Eli Zaretskii
a722e7dd15 Merge branch 'emacs-29' of git.savannah.gnu.org:/srv/git/emacs into emacs-29 2023-06-29 21:23:12 +03:00
Eli Zaretskii
65f146cf1c ; * lisp/calculator.el (calculator-need-3-lines): Fix last change. 2023-06-29 21:21:28 +03:00
john muhl
9e8386bdac Support cons cell as value of ':line-width' box attribute
* lisp/calculator.el (calculator-need-3-lines): Support
values of a face's ':line-width' box attribute that are
cons cells.  (Bug#64344)

Copyright-paperwork-exempt: yes
2023-06-29 21:18:30 +03:00
Yuan Fu
1d2ba6b363
; * admin/notes/tree-sitter/treesit_record_change: Update. 2023-06-29 11:15:30 -07:00
Yuan Fu
02b6be892f
Add missing calls to treesit_record_change in editfns.c
These should be all that are missing.  See the next commit for detail.

* src/editfns.c (Ftranslate_region_internal):
(Ftranspose_regions): Call treesit_record_change.
2023-06-29 11:15:29 -07:00
Yuan Fu
e982192e93
Call treesit_record_change in subst-char-in-region (bug#64329)
* src/editfns.c (Fsubst_char_in_region): Call treesit_record_change in
the else branch.
2023-06-29 11:15:29 -07:00