1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-03 08:30:09 +00:00
Commit Graph

7682 Commits

Author SHA1 Message Date
Eli Zaretskii
bb4b511c4c * etc/NEWS: Document changes to coding-system mnemonics. 2023-07-08 11:47:32 +03:00
Spencer Baugh
1930312992 ; * etc/NEWS: News entry for previous change (bug#62164). 2023-07-06 10:49:59 +03:00
Eli Zaretskii
ea845e3fcd ; * etc/NEWS: Fix punctuation and whitespace of last added entry. 2023-07-06 10:33:43 +03:00
Hugo Heagren
c296bcc6c4 Support right-align in mode-line
* lisp/bindings.el (mode-line-right-align-edge):  New custom
variable, controls where `mode-line-format-right-align' should
align to.
(mode-line-format-right-align):  New function.  If the symbol
`mode-line-format-right-align' appears in `mode-line-format',
then return return a padding string which aligns everything
after that symbol to the right.  Padding width is altered with
the display property and depends on the value of
`mode-line-right-align-edge'.
(mode-line-format-right-align):  New variable.  Convenience
definition for including right alignment in `mode-line-format'.
* doc/lispref/modes.texi (Mode Line Variables):  Document new
alignment functionality and user option.  (Bug#62606)
2023-07-06 10:31:46 +03:00
Michael Albinus
2dc7798449 `remote-file-name-access-timeout' being 0 is equal to nil
* doc/lispref/files.texi (Testing Accessibility): Clarify the
value of remote-file-name-access-timeout.

* etc/NEWS: Clarify the value of remote-file-name-access-timeout.

* lisp/files.el (remote-file-name-access-timeout): Adapt docstring.

* lisp/net//tramp.el (with-tramp-timeout): Ensure, that the
timeout is a positive number, or nil.
(tramp-handle-access-file): Simplify code.
2023-07-05 10:05:44 +02:00
Robert Pluim
a2db9b426b Improve remote-file-name-access-timeout NEWS entries
* etc/NEWS: Improve recentf and desktop mode entries.
2023-07-04 19:03:56 +02:00
Eli Zaretskii
85ac3b84af ; * etc/NEWS: Fix recently added entry. 2023-07-04 19:35:28 +03:00
Michael Albinus
b34f9a4439 Apply remote-file-name-access-timeout in desktop.el and recentf.el
* doc/emacs/files.texi (File Conveniences):
* doc/emacs/misc.texi (Saving Emacs Sessions):
Mention remote-file-name-access-timeout.

* doc/misc/tramp.texi (Frequently Asked Questions): Add note.

* etc/NEWS: Explain use of 'remote-file-name-access-timeout' in
desktop.el and recentf.el.

* lisp/desktop.el (desktop-access-file): New defun.
(desktop-restore-file-buffer): Use it.

* lisp/recentf.el (recentf-access-file): New defun.
(recentf-keep-default-predicate): Use it.

* lisp/net/tramp.el (tramp-handle-access-file): Improve error handling.
2023-07-04 15:27:03 +02:00
Harald Jörg
4d49b9bad4 cperl-mode: Announce the news in etc/NEWS
* etc/NEWS: add to the entry "CPerl mode".
2023-07-03 23:06:49 +02:00
Michael Albinus
c565a6c62c Add user option remote-file-name-access-timeout
* doc/lispref/files.texi (Testing Accessibility):
Add user option remote-file-name-access-timeout.

* doc/misc/tramp.texi (Frequently Asked Questions):
Explain remote-file-name-access-timeout.

* etc/NEWS: Mention 'remote-file-name-access-timeout'.

* lisp/files.el (remote-file-name-access-timeout): New defcustom.
(remote-file-name-inhibit-auto-save-visited)
(remote-file-name-inhibit-locks, remote-file-name-inhibit-cache)
(remote-file-name-inhibit-delete-by-moving-to-trash):
* lisp/simple.el (remote-file-name-inhibit-auto-save): Add group `tramp'.

* lisp/net/tramp.el (with-tramp-timeout, with-tramp-suspended-timers):
New defmacros.
(tramp-dont-suspend-timers): New defvar.
(tramp-handle-access-file): Implement handling of
`remote-file-name-access-timeout'.  (Bug#64401)
(tramp-action-show-and-confirm-message, tramp-process-actions)
(with-tramp-locked-connection, tramp-wait-for-regexp)
(tramp-read-passwd, tramp-read-passwd-without-cache): Use the macros.

* test/lisp/net/tramp-tests.el (remote-file-name-access-timeout):
Declare.
(tramp-test18-file-attributes): Extend test.
2023-07-03 18:24:11 +02:00
Mattias Engdegård
3ac4b2de77 * etc/NEWS: Announce addition of duplicate-region-final-position. 2023-07-03 13:15:53 +02: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
Eli Zaretskii
5b7e999e24 ; Fix documentation of last change
* lisp/net/eww.el (eww-copy-alternate-url): Doc fix.
* etc/NEWS:
* doc/misc/eww.texi (Basics): Minor wording and punctuation fixes.
(Bug#64126)
2023-06-24 14:58:44 +03:00
Eshel Yaron
dfba4347c7 New command 'eww-copy-alternate-url'
This adds a new command to EWW that copies an alternate link to the
currently visited page into the kill ring.  This is useful for
subscribing to website feeds, etc.

* lisp/net/eww.el (eww--alternate-urls, eww-read-alternate-url):
 New functions.
(eww-copy-alternate-url): New command.
(eww-mode-map): Bind it to 'A'.

* doc/misc/eww.texi (Basics): Document it.

* etc/NEWS: Announce it.
(Bug#64126)
2023-06-24 14:52:23 +03:00
Michael Albinus
77c2f05d77 Extend Tramp kubernetes method
* doc/misc/tramp.texi (Inline methods): Adapt kubernetes method.

* etc/NEWS: Describe changes in Tramp kubernetes method.

* lisp/net/tramp-container.el (tramp-kubernetes-context)
(tramp-kubernetes-namespace): New defcustoms.
(tramp-kubernetes--completion-function): Extend for CONTAINER.POD
syntax.
(tramp-kubernetes--host-name-regexp): New defconst.
(tramp-kubernetes--container, tramp-kubernetes--pod)
(tramp-kubernetes--current-context): New defuns.
(tramp-kubernetes--current-context-data): Simplify.
(tramp-kubernetes--context-namespace): New defun.
(tramp-methods) <kubernetes>: Respect container, context and
namespace.  (Bug#59797)
(tramp-container-connection-local-default-kubernetes-variables):
New defconst.  Set respective connection-local variables.

* lisp/net/tramp-sh.el (tramp-config-check): New variable.
(tramp-open-connection-setup-interactive-shell): Use it.

* lisp/net/tramp.el (tramp-methods): Adapt docstring.
(tramp-extra-expand-args): New defvar.
(tramp-expand-args): Use it.
2023-06-23 21:26:14 +02:00
Michael Albinus
1c499c18af ; * etc/NEWS: Fix typos. 2023-06-23 21:15:13 +02:00
Eli Zaretskii
01ce70cea9 Revert "Avoid header line with some empty non-nil formats"
This reverts commit 4f66cbbfe5.
This is part of removing the recently-added feature whereby
certain non-nil values of 'header-line-format' could signal
that the header line shall not be displayed.  The feature is
being reverted because its advantages are very minor, whereas
the complications it causes are serious.
2023-06-23 13:50:15 +03:00
Mattias Engdegård
a23a09a82f * etc/NEWS: Announce the fix for bug#44418 (,@ prefix syntax) 2023-06-22 13:22:47 +02:00
Mattias Engdegård
be91192ecb Straighten regexp postfix operator after zero-width assertion parse
The zero-width assertions \` \' \b \B were parsed in a sloppy way so
that a following postfix repetition operator could yield surprising
results.  For instance, "\\b*" would act as "\\b\\*", and "xy\\b*"
would act as "\\(?:xy\\b\\)*".

Except for \` and ^, any following postfix operator now applies to the
zero-width assertion itself only, which is predictable and consistent
with other assertions, if useless in practice.
For historical compatibility, an operator character following \` and ^
always becomes a literal. (Bug#64128)

* src/regex-emacs.c (regex_compile):
Set `laststart` appropriately for each zero-width assertion instead
of leaving it with whatever value it had before.
Remove a redundant condition.
* test/src/regex-emacs-tests.el
(regexp-tests-zero-width-assertion-repetition): New test.
* doc/lispref/searching.texi (Regexp Special):
Say that repetition operators are not special after \`,
and that they work as expected after other backslash escapes.
* etc/NEWS: Announce.
2023-06-21 18:00:26 +02:00
Sean Whitton
f16064f6bc Delete eval-command-interactive-spec
* etc/NEWS: Delete announcement of eval-command-interactive-spec.
* lisp/emacs-lisp/subr-x.el (eval-command-interactive-spec): Delete.
2023-06-21 13:26:09 +01:00
Po Lu
db6de49f23 Allow displaying tool bar on the bottom of the frame
* src/xterm.c (x_clear_under_internal_border): Subtract bottom
margins before clearing bottom border.
(XTflash): Subtract bottom margins before flashing mini window.

* src/xfns.c (x_set_tool_bar_position): Allow setting different
values outside of GTK+.
(frame_geometry): Adjust inner width and height for tool bars
placed on the bottom.

* src/xdisp.c (init_xdisp): Calculate using top margins only.

* src/window.c (resize_frame_windows): Fix commentary.

* src/w32fns.c (Fw32_frame_geometry): Report tool bar position
correctly.
(w32_clear_under_internal_border): Subtract bottom margins
prior to clearing bottom border.
(w32_set_tool_bar_position): New function.
(Fw32_frame_edges): Subtract bottom tool bar from inner width and
height.
(w32_frame_parm_handlers): Add `set_tool_bar_position' parameter
handler.

* src/pgtkterm.c (pgtk_flash): Subtract bottom
margins before clearing bottom border.
(XTflash): Subtract bottom margins before flashing mini window.

* src/pgtkfns.c (frame_geometry): Set `inner_top' correctly.
(Fpgtk_set_mouse_absolute_pixel_position):
(Fpgtk_mouse_absolute_pixel_position):
(Fpgtk_page_setup_dialog):
(Fpgtk_get_page_setup): Wrap lines which cause C Mode to hang.

* src/nsterm.m (ns_clear_under_internal_border): Subtract bottom
margins before clearing bottom border.

* src/nsfns.m (ns_set_tool_bar_position): New function.  Error if
arg is not top.
(ns_frame_parm_handlers): Add that as the handler for
`tool-bar-position', to prevent it from being set to an invalid
value.

* src/haikuterm.c (haiku_flash): Subtract bottom margins before
flashing mini window.
(haiku_clear_under_internal_border): Subtract bottom margins
before clearing bottom border.

* src/haikufns.c (haiku_set_tool_bar_position): Allow setting
values other than `top'.
(frame_geometry): Take bottom margin into account when calculating
inner dimensions.

* src/frame.h (struct frame): Always define `tool_bar_position'.
(fset_tool_bar_position): Define function everywhere.
(FRAME_TOOL_BAR_POSITION): Define correctly on all toolkits.
(FRAME_TOOL_BAR_TOP_HEIGHT):
(FRAME_TOOL_BAR_TOP_LINES):
(FRAME_TOOL_BAR_BOTTOM_HEIGHT):
(FRAME_TOOL_BAR_BOTTOM_LINES): New macros.  Each pair returns the
tool bar dimensions only if the tool bar position is set
appropriately.
(FRAME_TOP_MARGIN, FRAME_TOP_MARGIN_HEIGHT): Only add tool bar
height if it is placed at the top of the frame.
(FRAME_BOTTOM_MARGIN, FRAME_BOTTOM_MARGIN_HEIGHT): Add ``bottom
margins''.
(FRAME_MARGINS, FRAME_MARGIN_HEIGHT): Move original margin macro
here.
(FRAME_PIXEL_HEIGHT_TO_TEXT_LINES):
(FRAME_TEXT_TO_PIXEL_HEIGHT):
(FRAME_PIXEL_TO_TEXT_HEIGHT):
(FRAME_INNER_HEIGHT): Subtract both vertical margins.

* src/frame.c (adjust_frame_size): Subtract both top and bottom
margins to determine the inner height.
(make_frame): Initialize `f->tool_bar_position' unconditionally.

* src/dispnew.c (adjust_frame_glyphs_for_window_redisplay): Place
internal tool bar on bottom if requested.

* doc/lispref/frames.texi (Frame Layout): Describe the possibility
of the tool bar being placed below the inner area of the frame.
(Layout Parameters): Describe that `tool-bar-position' is now
supported almost everywhere.
2023-06-21 10:06:34 +08:00
Stefan Monnier
017475a70e * doc/lispref/streams.texi (Output Variables): Document pp-default-function 2023-06-17 17:27:52 -04:00
Eli Zaretskii
4c975111af ; * etc/NEWS: Backward compatibility with 'doc-view-svg-face'. 2023-06-13 16:42:38 +03:00
Eshel Yaron
4f66cbbfe5 Avoid header line with some empty non-nil formats
Allow the value of 'header-line-format' to indicate that no header
line should be displayed when it trivially yields 'nil', even if it is
not plain 'nil'.  Previously, any non-nil 'header-line-format'
resulted in a (possibly empty) header line.  This change adds some
flexibility by also taking a non-nil value of 'header-line-format' to
mean that no header line should be displayed if it's a list whose
'car' is a symbol and either that symbol is ':eval' and the second
list element evaluates to 'nil', or the symbol's value as a variable
is 'nil' or void.
(Bug#63825)

* src/xdisp.c (safe_eval_inhibit_quit): New function.
* src/lisp.h (safe_eval_inhibit_quit): Declare it.
* src/window.c (null_header_line_format): New function.
(window_wants_header_line): Use it.

* doc/lispref/modes.texi (Header Line): Update to reflect new
conditions for displaying a window's header line.

* etc/NEWS: Announce updated treatment of 'header-line-format'.
2023-06-06 15:08:31 +03:00
Sean Whitton
a30781399b * subr-x (eval-command-interactive-spec): New function. 2023-06-04 20:16:55 +01:00
Michael Albinus
5cace109d2 ; * etc/NEWS: Fix typos. 2023-05-31 08:45:08 +02:00
Andrea Corallo
ecc1d990d9 'describe-function' shows function inferred type when available
* lisp/help-fns.el (help-fns--signature): Print function type for
native compiled code.
* etc/NEWS: Add entry.
2023-05-30 18:28:25 +02:00
Protesilaos Stavrou
cb1ee63e2a
Update modus-themes to their version 4.2.0
* doc/misc/modus-themes.org: Update the manual.

* etc/themes/modus-operandi-tritanopia-theme.el:
* etc/themes/modus-vivendi-tritanopia-theme.el: Add new themes
  optimized for users with blue-yellow color deficiency (tritanopia).

* etc/themes/modus-operandi-deuteranopia-theme.el:
* etc/themes/modus-operandi-theme.el:
* etc/themes/modus-operandi-tinted-theme.el:
* etc/themes/modus-vivendi-deuteranopia-theme.el:
* etc/themes/modus-vivendi-theme.el:
* etc/themes/modus-vivendi-tinted-theme.el: Update theme files.

* etc/themes/modus-themes.el: Update main file to the latest version.

* etc/NEWS: Rephrase the announcement about the new Modus themes to
  also mention the tritanopia-optimized items.

Detailed release notes here:
<https://protesilaos.com/codelog/2023-05-30-modus-themes-4-2-0/>.
2023-05-30 09:37:24 +03:00
Eshel Yaron
f35648ba0c Add customization options for dictionary-search
Allow users to customize 'dictionary-search' via several new
customization options.

* lisp/net/dictionary.el (dictionary-define-word)
(dictionary-match-word, dictionary-completing-read-word)
(dictionary-dictionaries, dictionary-completing-read-dictionary)
(dictionary-display-definition-in-help-buffer): New functions.
(dictionary-read-word-prompt)
(dictionary-display-definition-function)
(dictionary-read-word-function)
(dictionary-read-dictionary-function)
(dictionary-search-interface): New user options.
(dictionary-search): Use them.
(dictionary-read-dictionary-default)
(dictionary-read-word-default): New functions, extracted from
'dictionary-search'.
* etc/NEWS: Announce.
2023-05-26 12:12:44 +03:00
Eli Zaretskii
71622d70e8 New Rmail commands for reading mailing-lists
* lisp/mail/rmail.el (rmail--mailing-list-message): New internal
function.
(rmail-mailing-list-help, rmail-mailing-list-post)
(rmail-mailing-list-unsubscribe, rmail-mailing-list-archive): New
commands.
(rmail-mode-map): Add menu items for the new commands.

* etc/NEWS: Announce the new Rmail commands.
2023-05-21 13:57:14 +03:00
Mattias Engdegård
bd6bba4780 Improved copy-tree documentation and test (bug#63509)
* etc/NEWS: Move entry since it's an incompatible change.
* lisp/emacs-lisp/shortdoc.el (vector): Make the example relevant.
* lisp/subr.el (copy-tree): Rename second argument,
since 'vector-like' is a term with a specific meaning in Emacs
but not the one intended here.
* doc/lispref/lists.texi (Building Lists): Rename second argument,
and make it clear that the input must be acyclic.
* doc/lispref/records.texi (Record Functions):
Be more precise: `copy-sequence` is used to copy records,
`copy-tree` copies trees made of records etc.
* test/lisp/subr-tests.el (subr--copy-tree): Extend and strengthen the
test considerably, using the print-circle trick to detect structure
sharing precisely.
2023-05-19 15:50:42 +02:00
Eli Zaretskii
7ef20e0c81 Minor fixes of last change
* etc/NEWS:
* doc/lispref/records.texi (Record Functions): Improve wording.
(Bug#63509)
2023-05-19 09:05:45 +03:00
Joseph Turner
3a1285caba Make 'copy-tree' work with records
* doc/lispref/lists.texi (Building Cons Cells and Lists): Document
new behavior of 'copy-tree'.
* doc/lispref/records.texi (Record Functions): Cross-reference to
lists.texi.
* etc/NEWS: Mention change.  (Bug#63509)
* lisp/emacs-lisp/shortdoc.el: Add 'copy-tree' example to vector
group.
* lisp/subr.el (copy-tree): Recurse into records as well as
vectors when optional second argument is non-nil. Rename second
argument from VECP to VECTOR-LIKE-P.
* test/lisp/subr-tests.el: Test new behavior.
2023-05-19 09:00:27 +03:00
Tony Zorman
2ce279680b Add :vc keyword to use-package for VC package support
* lisp/use-package/use-package-core.el (use-package-keywords): Add :vc.
(use-package-handler/:load-path): Insert 'load-path' into 'state'.
(use-package-vc-install): Install the package with package-vc.el.
(use-package-handler/:vc): Handler for the :vc keyword.
(use-package-normalize--vc-arg): Normalization for more complex
arguments to 'use-package-normalize/:vc', in order to make them
compatible with the specification of 'package-vc-selected-packages'.
(use-package-normalize/:vc): Normalizer for the :vc keyword.
(use-package): Document :vc.
* lisp/use-package/use-package-ensure.el (use-package-handler/:ensure):
Do not ensure a package when :vc is used in the declaration.
* test/lisp/use-package/use-package-tests.el (use-package-test/:vc-1):
(use-package-test/:vc-2):
(use-package-test/:vc-3):
(use-package-test/:vc-4):
(use-package-test/:vc-5):
(use-package-test-normalize/:vc):
Add tests for :vc.
* etc/NEWS: Mention change.  (Bug#60418)
2023-05-16 21:22:05 +02:00
Joseph Turner
5ac08768aa Support side-effects while building VC packages
* doc/emacs/package.texi (Specifying Package Sources): Document new
specification attributes.
* lisp/emacs-lisp/package-vc.el (package-vc-allow-side-effects): Add
new user option.
(package-vc--make): Add handler for processing :make and
:shell-command.
(package-vc--unpack-1): Check 'package-vc-allow-side-effects' and
invoke 'package-vc--make'.
* etc/NEWS: Mention change.  (Bug#63336)
2023-05-16 21:22:02 +02:00
Mattias Engdegård
9f856e4cd0 Use mutate-constant as warning identifier
* etc/NEWS:
* lisp/emacs-lisp/byte-run.el (with-suppressed-warnings):
* lisp/emacs-lisp/bytecomp.el (byte-compile-warnings)
(byte-compile-form):
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-test--with-suppressed-warnings):
Use the new warning name `mutate-constant` instead of using the
somewhat overloaded `suspicious`.
2023-05-13 14:30:59 +02:00
Mattias Engdegård
bfc07100d2 Byte-compiler warning about mutation of constant values
When we can easily detect mutation of constants (quoted lists, strings
and vectors), warn.  For example,

  (setcdr '(1 . 2) 3)
  (nreverse [1 2 3])
  (put-text-property 0 3 'face 'highlight "moo")

Such code can result in surprising behaviour and problems that
are difficult to debug.

* lisp/emacs-lisp/bytecomp.el (byte-compile-form, mutating-fns):
Add the warning and a list of functions to warn about.
* etc/NEWS: Announce.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-test--with-suppressed-warnings): Add test cases.
2023-05-13 11:53:25 +02:00
Antero Mejr
f24ea84f43 Add safe-local-variable-directories variable.
This variable can be set to automatically load risky dir-local
variables from a list of trusted directories.

* lisp/emacs-lisp/files.el (safe-local-variable-directories,
hack-local-variables-filter, hack-local-variables-confirm): New
variable and associated logic.
* test/lisp/files-tests.el
(files-tests-safe-local-variable-directories): Add tests for same.
* doc/emacs/custom.texi (Safe File Variables): Add documentation for
same.
* doc/lispref/variables.texi (File Local Variables): Add documentation
for same.
* etc/NEWS (Lisp Changes in Emacs 30.1): Add news entry for
same.  (Bug#61901)
2023-05-11 16:33:16 +03:00
Jim Porter
40d6609563 Use connection-aware functions when getting the UID/GID in Eshell
This means, for example, that when using Tramp to sudo in Eshell, "rm"
queries the user before deleting anything (bug#63221).

* lisp/eshell/esh-util.el (eshell-user-login-name): New function...
* lisp/eshell/em-unix.el (eshell/whoami): ... use it.

* lisp/eshell/em-ls.el (eshell-ls-applicable): Use 'file-user-uid' and
'eshell-user-login-name'.
(eshell-ls-decorated-name): Use 'file-user-uid'.

* lisp/eshell/em-pred.el (eshell-predicate-alist): Use 'file-user-uid'
and 'file-group-gid'.

* lisp/eshell/em-unix.el (eshell-interactive-query): New widget...
(eshell-rm-interactive-query, eshell-mv-interactive-query)
(eshell-cp-interactive-query, eshell-ln-interactive-query): ... use
it.
(eshell-interactive-query-p): New function...
(eshell/rm, eshell/mv, eshell/cp, eshell/ln): ... use it.

* lisp/simple.el (file-group-gid): New function.

* lisp/net/ange-ftp.el (ange-ftp-file-group-gid): New function...
(file-group-gid): ... use it.

* lisp/net/tramp.el (tramp-handle-file-group-gid):
* lisp/net/tramp-archive.el (tramp-archive-handle-file-group-gid): New
functions.

* lisp/net/tramp.el (tramp-file-name-for-operation): Add
'file-group-gid'.

* lisp/net/tramp-adb.el (tramp-adb-file-name-handler-alist):
* lisp/net/tramp-archive.el (tramp-archive-file-name-handler-alist):
* lisp/net/tramp-crypt.el (tramp-crypt-file-name-handler-alist):
* lisp/net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist):
* lisp/net/tramp-rclone.el (tramp-rclone-file-name-handler-alist):
* lisp/net/tramp-sh.el (tramp-sh-file-name-handler-alist):
* lisp/net/tramp-smb.el (tramp-smb-file-name-handler-alist):
* lisp/net/tramp-sshfs.el (tramp-sshfs-file-name-handler-alist):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-file-name-handler-alist):
Add 'file-group-gid' mapping.

* test/lisp/net/tramp-tests.el (tramp-test44-file-user-group-ids):
* test/lisp/net/tramp-archive-tests.el
(tramp-archive-test44-file-user-group-ids): Add tests for
'file-group-gid'.

* doc/lispref/files.texi (Magic File Names): Mention 'file-group-gid'.

* doc/lispref/os.texi (User Identification): Document
'file-group-gid', and move 'group-real-gid' to match the order of
'user-real-uid'.

* etc/NEWS: Announce 'file-group-gid'.
2023-05-02 21:28:34 -07:00
Mattias Engdegård
7acb3f1c06 Add the function declaration and property important-return-value
Now the declaration

 (declare (important-return-value t))

can be used to have the byte-compiler warn when the return value from
a call is discarded (bug#61730).

* lisp/emacs-lisp/bytecomp.el (byte-compile-form)
(important-return-value-fns): Use the function property
`important-return-value` instead of looking through a static list.
* lisp/emacs-lisp/byte-run.el (byte-run--set-important-return-value)
(defun-declarations-alist): New function declaration, setting the
property of the same name.
* lisp/emacs-lisp/cl-macs.el:
* lisp/subr.el (assoc-default): Set the property.
* doc/lispref/functions.texi (Declare Form):
* doc/lispref/symbols.texi (Standard Properties): Document.
* etc/NEWS: Announce.
2023-05-01 17:11:50 +02:00
Michael Albinus
022f50ebe6 New command 'tramp-cleanup-some-buffers'
* doc/misc/tramp.texi (Cleanup remote connections):
Document tramp-cleanup-some-buffers and
tramp-cleanup-some-buffers-hook.

* etc/NEWS: New command 'tramp-cleanup-some-buffers'.

* lisp/net/tramp.el (tramp-handle-make-process):
* lisp/net/tramp-adb.el (tramp-adb-handle-make-process):
* lisp/net/tramp-sh.el (tramp-sh-handle-make-process):
Use `tramp-taint-remote-process-buffer'.

* lisp/net/tramp.el (tramp-post-process-creation): New defun.
(tramp-handle-make-process):
* lisp/net/tramp-adb.el (tramp-adb-maybe-open-connection):
* lisp/net/tramp-crypt.el (tramp-crypt-maybe-open-connection):
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-file-notify-add-watch)
(tramp-gvfs-maybe-open-connection):
* lisp/net/tramp-rclone.el (tramp-rclone-maybe-open-connection):
* lisp/net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band)
(tramp-sh-handle-file-notify-add-watch)
(tramp-maybe-open-connection):
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-directory)
(tramp-smb-handle-file-acl, tramp-smb-handle-set-file-acl)
(tramp-smb-maybe-open-connection):
* lisp/net/tramp-sshfs.el (tramp-sshfs-maybe-open-connection):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-maybe-open-connection)
(tramp-sudoedit-send-command): Use it.

* lisp/net/tramp-cmds.el (tramp-tainted-remote-process-buffers):
New defvar.
(tramp-cleanup-dired-buffer-p)
(tramp-delete-tainted-remote-process-buffer-function)
(kill-buffer-hook, tramp-cleanup-remote-process-p)
(tramp-cleanup-some-buffers): New defuns.
(tramp-cleanup-some-buffers-hook): New defcustom.  Add
`buffer-file-name', `tramp-cleanup-dired-buffer-p' and
`tramp-cleanup-remote-process-p' to the hook.
(kill-buffer-hook):
Add `tramp-delete-tainted-remote-process-buffer-function'.
(tramp-cleanup-all-buffers): Rework.

* lisp/net/tramp-compat.el (tramp-compat-always): New defalias.

* test/lisp/net/tramp-tests.el (tramp--test-always): Delete.
(tramp-test10-write-region, tramp-test21-file-links)
(tramp--test-deftest-direct-async-process)
(tramp-test37-make-auto-save-file-name)
(tramp-test38-find-backup-file-name)
(tramp-test39-make-lock-file-name)
(tramp-test39-detect-external-change): Use `tramp-compat-always'.
2023-04-26 18:06:39 +02:00
Eli Zaretskii
fa4eae191c ; * etc/NEWS: Fix last change. 2023-04-25 17:31:05 +03:00
Antero Mejr
c7fc4c8119 eww: Provide completions for bookmarks and suggested URIs.
* lisp/net/eww.el (eww): Add the result of 'eww-suggest-uris' to the
completion collection argument.
(eww-bookmark-urls): New procedure.
(eww-suggest-uris): Add "eww-bookmark-urls" to the default list.
* etc/NEWS (EWW): Add NEWS entry for the change.  (Bug#62800)
2023-04-25 17:29:23 +03:00
Antero Mejr
df6cc4d33b eww: Enable completion in URL/keyword prompt.
* lisp/net/eww.el (eww): Use 'completing-read' when prompting for a URL
or keywords.
(eww-minibuffer-url-keymap): New keymap for use in the URL/keyword
prompt.
* etc/NEWS (EWW): Add NEWS entry for the change.  (Bug#62800)
2023-04-25 17:28:10 +03:00
Eshel Yaron
2ef6f943ab Add option to control default outlining in 'C-h b'
* lisp/help.el (describe-bindings-outline-rules): New user option.
(describe-bindings): Use it instead of hardcoding "Key translations".
(Bug#62708)
2023-04-24 14:42:00 +03:00
Michael Albinus
2e85ac2b27 Add new Tramp method "flatpak"
* doc/misc/tramp.texi (Inline methods): Add flatpak.

* etc/NEWS: Add new Tramp method "flatpak".  Fix typos.

* lisp/net/tramp-container.el (tramp-flatpak-program): New defcustom.
(tramp-flatpak-method): New defconst.
(tramp-flatpak--completion-function): New defun.  Set it for "flatpak".
(tramp-methods) <flatpak>: Add.
(tramp-container-connection-local-default-flatpak-variables):
New defconst.  Set respective connection-local variables.
2023-04-23 13:37:39 +02:00
Eli Zaretskii
c14a41c24c ; * etc/NEWS: Fix last change. (Bug#62696) 2023-04-22 12:29:55 +03:00
kobarity
711e8bc717 Add a new user option in Python mode to improve the indentation
* lisp/progmodes/python.el (python-indent-block-paren-deeper): New
user option.
(python-indent-context): Add a new context :inside-paren-from-block.
(python-indent--calculate-indentation): Modify according to
`python-indent-block-paren-deeper' and :inside-paren-from-block.
* test/lisp/progmodes/python-tests.el
(python-indent-inside-paren-block-1)
(python-indent-inside-paren-block-2)
(python-indent-inside-paren-block-3)
(python-indent-inside-paren-block-4): New tests.
(python-indent-inside-paren-5, python-indent-dedenters-8): Modify
according to the new context.
* etc/NEWS: Document the new user option.  (Bug#62696)
2023-04-22 12:28:37 +03:00