aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/erc/erc.el (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Use seq-doseq for iterating over strings in ERCF. Jason Park2026-01-111-3/+3
| | | | | | | * lisp/erc/erc-common.el (erc--doarray): Remove unused function. * lisp/erc/erc.el (erc--channel-mode-types, erc--process-channel-modes) (erc--parse-user-modes): Replace `erc--doarray' with `seq-doseq'. * test/lisp/erc/erc-tests.el (erc--doarray): Remove test.
* ; Add 2026 to copyright years.Sean Whitton2026-01-011-1/+1
|
* December 2025 spelling fixesPaul Eggert2025-12-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some of the fixes are to continue to use American rather than British spelling. * doc/misc/modus-themes.org (my-modus-themes-engraved-faces): Fix misspelled ‘:foreground’s. * etc/themes/modus-themes.el (modus-themes-faces): Fix misspelled ‘modus-themes-bold’. * lisp/emacs-lisp/rx.el (rx--normalize-char-pattern): Rename from rx--normalise-char-pattern. (rx--optimize-or-args): Rename from rx--optimise-or-args. * lisp/frame.el (frame--special-parameters): Fix misspelled "right-divider-width". * lisp/net/tramp.el (tramp-fingerprint-prompt-regexp): Use American spelling “centered”, to match current libfprintf. * lisp/org/org-fold-core.el (org-fold-core--optimize-for-huge-buffers): Rename from org-fold-core--optimise-for-huge-buffers. (org-fold-core-update-optimization): Rename from org-fold-core-update-optimisation, leaving an alias behind. (org-fold-core-remove-optimization): Rename from org-fold-core-remove-optimisation, leaving an alias behind. * lisp/org/org.el (org-advertized-archive-subtree): This alias is now obsolete. * lisp/play/zone.el (zone-ignored-buffers): Fix misspelling of ‘zone--buffer-encrypted-p’. * lisp/progmodes/csharp-mode.el (csharp-ts-mode-faces): Fix misspelling of ‘csharp’ group. * lisp/vc/vc.el (vc-clonable-backends-custom-type): Rename from vc-cloneable-backends-custom-type, leaving an alias behind. * test/lisp/emacs-lisp/bytecomp-tests.el: (bytecomp-tests--warn-arity-non-compiled-callee): Rename from bytecomp-tests--warn-arity-noncompiled-callee. (bytecomp-test-defface-spec): Reword a deliberate misspelling of “default” that is so common I don’t want it to pollute the spelling dictionary. * test/lisp/emacs-lisp/package-vc-tests.el: (package-vc-tests-preserve-artifacts): Rename from package-vc-tests-preserve-artifacts. * test/lisp/eshell/em-prompt-tests.el: (em-prompt-test/forward-backward-paragraph-1): Reword a deliberate misspelling of “goodbye” that is so common I don’t want it to pollute the spelling dictionary.
* Fix regression involving erc-channel-user accessorsF. Jason Park2025-10-271-15/+31
| | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: New section for ERC 5.6.2 and new entry mentioning slight change in `erc-channel-user' accessor behavior. * lisp/erc/erc-common.el (erc-channel-user): Change type for status slot to natnum from integer. * lisp/erc/erc.el (erc-channel-user-signal-if-status-unknown): New variable. (erc--define-channel-user-status-compat-getter): Only use fallback in Non-ERC buffers because "obviously" a status flag is unusable if the server doesn't advertise it or, rather, advertises nonsupport via its absence. This regression was introduced in ERC 5.6. (erc-channel-begin-receiving-names): Sharp-quote function name. (erc--get-prefix-flag): Mention in doc that a return value of nil can also mean the status flag is not supported by the server. * test/lisp/erc/erc-tests.el (erc--parsed-prefix): Show that it returns nil in a non-ERC buffer. (erc-tests--make-combinations) (erc-tests--with-channel-user-status-accessors): New functions. (erc-channel-user/status-accessors/solo/default) (erc-channel-user/status-accessors/solo/ov) (erc-channel-user/status-accessors/multi/default) (erc-channel-user/status-accessors/multi/ov): New tests. (Bug#67220)
* Change ERC version to 5.6.2-gitF. Jason Park2025-10-271-3/+4
| | | | | | | * doc/misc/erc.texi: Change ERCVER to 5.6.2. * lisp/erc/erc.el (erc-version): Change working version to 5.6.2-git. Do the same for the package Version header and the `customize-package-emacs-version-alist' mapping.
* Release ERC 5.6.1F. Jason Park2025-10-211-2/+2
| | | | | | | | | * lisp/erc/erc.el: Change "Version" header from 5.6.1-git to 5.6.1. A `customize-package-emacs-version-alist' mapping to Emacs 31.1 was already added at some point during the course of development for this release. The ERCVER variable in doc/misc/erc.texi was updated when moving to the "-git" suffixed version. (erc-version): Change version from 5.6.1-git to 5.6.1.
* Use existing X-Debbugs-CC header in erc-bugF. Jason Park2025-08-241-2/+7
| | | | | | | | | | * lisp/erc/erc.el (erc-bug): On Emacs 30 and later, search for and ideally use an existing "X-Debbugs-CC" header instead of inserting a new one at the top. Section 4.5 Obsolete Header Fields of RFC 5322 says, "except for destination address fields (described in section 4.5.3), the interpretation of multiple occurrences of fields is unspecified." Anecdotal fiddling suggests the Savannah servers aren't confused by the second "empty" header field, so this change is probably just cosmetic.
* Use function-valued variable for ERC query predicateF. Jason Park2025-07-271-2/+8
| | | | | | | | | | | | | | | | * lisp/erc/erc-notify.el (erc-querypoll-mode, erc-querypoll-enable) (erc-querypoll-disable): Override `erc-query-table-synced-predicate' when mode is active. (erc--queries-current-p): Remove method. (erc--querypoll-active-p): New function. * lisp/erc/erc-speedbar.el (erc-speedbar-buttons) (erc-speedbar-insert-target): Call function-valued variable `erc--query-table-synced-predicate' instead of its now default value `erc--queries-current-p' directly. * lisp/erc/erc.el (erc--query-table-synced-predicate): New variable. (erc--queries-current-p, erc--query-participant-present-p): Convert former from method to normal function and rename to latter. Original was added as part of bug#70928.
* Use .pem extension for client certs in ERC docsF. Jason Park2025-02-211-9/+8
| | | | | | | | | * doc/misc/erc.texi (Connecting): Change file-name extensions to .pem in all examples, and explain that the key and the cert can be combined into one file. (SASL): Use .pem extension for certs. * lisp/erc/erc.el (erc--warn-once-before-connect): Revise doc. (erc-tls): Use .pem extension for certs. (Bug#76278)
* Prefer cl-evenp/cl-oddp in some placesStefan Kangas2025-02-171-1/+1
| | | | | | | | | | | | | | * lisp/erc/erc.el (erc-format-message): * lisp/obsolete/thumbs.el (thumbs-emboss-image): * lisp/org/org-capture.el (org-capture-escaped-%): * lisp/org/org-element-ast.el (org-element-create): * lisp/org/org-macro.el (org-macro-extract-arguments): * lisp/org/org-persist.el (org-persist--get-collection): * lisp/org/ox-odt.el (org-odt-get-table-cell-styles): * lisp/org/ox.el (org-export--dispatch-ui): * lisp/progmodes/cperl-mode.el (cperl-forward-re) (cperl-find-pods-heres): Prefer 'cl-evenp/'cl-oddp' to free-coding them in some files that already depend on cl-lib in run-time.
* More clearly define local module behavior in ERCF. Jason Park2025-02-071-1/+3
| | | | | | | | | | | | | | | | | | | | | | * doc/misc/erc.texi (Modules): Label all local modules as being such. Move `querypoll' to the auxiliary section. Rework entire "Local Modules" portion. * lisp/erc/erc-goodies.el (erc-keep-place-indicator-mode) (erc-command-indicator-mode): Mention what buffer types they operate in. * lisp/erc/erc-nicks.el (erc-nicks-mode): Mention the mode is enabled in all buffers. * lisp/erc/erc-notify.el (erc-querypoll-mode): Mention which buffers it operates in. * lisp/erc/erc-sasl.el (erc-sasl-mode): Disable completely in target buffers so its mode variable is nil. * lisp/erc/erc-services.el (erc-services-regain-mode): Disable in target buffers. * lisp/erc/erc.el (erc-open): When activating local modules, skip those that have just been enabled by a fellow module. Do this even though their setup code is meant to be idempotent. * test/lisp/erc/erc-scenarios-base-local-modules.el (erc-scenarios-base-local-modules--toggle-helpers): Revise to assert current behavior. (Bug#57955)
* ; Remove obsolete :options value from erc-mode-hookF. Jason Park2025-02-021-3/+4
| | | | | * lisp/erc/erc.el (erc-mode-hook): Remove `erc-add-scroll-to-bottom' from :options list because the function has been deprecated.
* Reuse client cert for connectivity probing in ERCF. Jason Park2025-01-221-0/+2
| | | | | | | | | | | | | | | | | | | | * lisp/erc/erc-backend.el (erc--server-connect-function) (erc--server-post-dial-function): Rename former to latter because the existing name is better suited for the eventual generalizing of `erc-server-connect' in a future version. (erc-server-connect): Use new name for `erc--server-connect-function', `erc--server-post-dial-function'. (erc--recon-probe-reschedule, erc--recon-probe-sentinel) (erc--recon-probe-filter, erc--recon-probe-check): New functions factored out of `erc-server-delayed-check-reconnect'. (erc-server-delayed-check-reconnect): Refactor, splitting off lambdas into top-level functions for improved tracing. * lisp/erc/erc.el (erc-message-english-recon-probe-hung-up) (erc-message-english-recon-probe-nobody-home): New variables. (Bug#62044) Thanks to Libera.Chat user arjan for reporting this bug, which is new in ERC 5.6 and Emacs 30.1.
* Update copyright year to 2025Paul Eggert2025-01-011-1/+1
| | | | Run "TZ=UTC0 admin/update-copyright".
* ; Slightly improve test case for erc-parse-modesF. Jason Park2024-12-091-3/+3
| | | | | | | * lisp/erc/erc.el (erc--merge-local-modes): Look for a symbol's `erc-module' property before examining its name. * test/lisp/erc/erc-tests.el (erc-parse-modes): Expand case to cover alternating plus and minus mode changes.
* Reserve erc-normalize-port for equality comparisonsF. Jason Park2024-12-011-25/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: Add entry explaining changes to entry point 'erc-tls' and library functions `erc-normalize-port' and `erc-compute-port'. * lisp/erc/erc.el (erc-normalize-port): Map "ircu" to 6665 instead of 6667, and add related IANA service mappings. Return 0 for unknown nonempty strings. (erc-open): Pass `erc-session-port' through `erc-string-to-port' before handing it to `erc-server-connect'. This prevents the network machinery from ever seeing a numeric string, like "6667". (erc-select-read-args): Since `erc-compute-port' no longer relies on `erc-normalize-port', ensure its input is a number. Use `erc-port-equal' instead of `eql'. (erc-tls): Respect a configured non-nil `erc-port' option when the user does not provide a :port keyword argument from Lisp code. (erc-determine-parameters): Use `erc-compute-port' for initializing `erc-session-port'. (erc-compute-port): Don't pass the result through `erc-normalize-port', which can convert it to an unintuitive form. (erc--url-default-connect-function): Use `erc-compute-port' instead of `erc-normalize-port'. (erc-handle-irc-url): Use `erc-port-equal' for comparison. * test/lisp/erc/erc-scenarios-auth-source.el (erc-scenarios-common--auth-source): Allow tests to convey the automatic port number to `erc-open' via `erc-port'. (erc-scenarios-base-auth-source-server--dialed): Use `erc-port' option instead of passing a :port parameter to entry-point command. * test/lisp/erc/erc-tests.el (erc-normalize-port): New test. (Bug#74516)
* Allow querying auth-source with port as string in ERCTrevor Arjeski2024-12-011-2/+3
| | | | | | | | | | | | | | * lisp/erc/erc.el (erc--auth-source-determine-params-defaults): Allow arbitrary strings for `ers-session-port'. Previously, if a port/service was any string other than "irc", the auth-source query would fail for a seemingly unknown reason. Restricting the value to "irc" is unnecessary since "irc" is already added to the list of ports, and `make-network-process' already consults /etc/services for well-known service names, like "ircs-u", etc. This change allows a user to (setopt erc-port "1234"), intentionally or accidentally, while still being able to use .authinfo for password management. (Bug#74516) Copyright-paperwork-exempt: yes
* Clear buffer-undo-list after sending input in ERCF. Jason Park2024-12-011-6/+4
| | | | | | | | | | | * lisp/erc/erc.el (erc-insert-line): Assume `erc-insert-marker' points somewhere. (erc-send-current-line): Set `buffer-undo-list' to nil because it should only record editing changes in the prompt area, which has just been cleared. ERC did this via `erc-display-prompt' prior to 5.6, but it now leaves the prompt alone by default. * test/lisp/erc/erc-tests.el (erc-update-undo-list): New test. (Bug#74518)
* Use helper to get erc-networks--id symbol as stringF. Jason Park2024-11-151-11/+7
| | | | | | | | | | | | | | * lisp/erc/erc-networks.el (erc-networks--id-string): New function. (erc-networks--construct-target-buffer-name) (erc-networks--ensure-unique-server-buffer-name) (erc-networks--rename-server-buffer): Use it. * lisp/erc/erc-nicks.el (erc-nicks-list-faces): Use it. * lisp/erc/erc-status-sidebar.el (erc-status-sidebar-pad-hierarchy): Use it. * lisp/erc/erc.el (erc-generate-new-buffer-name) (erc-log-irc-protocol) (erc--auth-source-determine-params-defaults) (erc-format-target-and/or-network): Use it. * test/lisp/erc/erc-networks-tests.el (erc-networks--id-string): New test.
* Mark if-let and when-let obsoleteSean Whitton2024-10-241-76/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/subr.el (if-let*, when-let*, if-let, when-let): Mark if-let and when-let obsolete (bug#73853 and elsewhere). Move docstring text around so that if-let* and when-let* descriptions no longer refer to if-let and when-let. * etc/NEWS: Announce the change. * admin/admin.el (reminder-for-release-blocking-bugs): * doc/misc/erc.texi (display-buffer): * lisp/ansi-color.el (ansi-color-apply) (ansi-color--face-vec-face): * lisp/ansi-osc.el (ansi-osc-apply-on-region) (ansi-osc-hyperlink): * lisp/arc-mode.el (archive-goto-file) (archive-next-file-displayer): * lisp/auth-source-pass.el (auth-source-pass-search) (auth-source-pass--parse-data) (auth-source-pass--find-match-many): * lisp/autorevert.el (auto-revert-notify-rm-watch): * lisp/buff-menu.el (Buffer-menu-unmark-all-buffers) (Buffer-menu-group-by-root): * lisp/calendar/parse-time.el (parse-iso8601-time-string): * lisp/cedet/pulse.el (pulse-tick): * lisp/comint.el (comint--fontify-input-ppss-flush-indirect) (comint--intersect-regions): * lisp/completion-preview.el (completion-preview--try-table) (completion-preview--capf-wrapper, completion-preview--update): * lisp/cus-edit.el (setopt--set) (custom-dirlocals-maybe-update-cons, custom-dirlocals-validate): * lisp/custom.el (load-theme): * lisp/descr-text.el (describe-char): * lisp/desktop.el (desktop--emacs-pid-running-p): * lisp/dired-x.el (menu): * lisp/dired.el (dired-font-lock-keywords) (dired-insert-directory, dired--insert-disk-space, dired-mode): * lisp/dnd.el (dnd-handle-multiple-urls): * lisp/dom.el (dom-remove-attribute): * lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker): * lisp/emacs-lisp/bytecomp.el (bytecomp--custom-declare): * lisp/emacs-lisp/comp-common.el (comp-function-type-spec): * lisp/emacs-lisp/comp-cstr.el (comp--all-classes) (comp-cstr-set-range-for-arithm, comp--cstr-union-1-no-mem) (comp-cstr-intersection-no-mem, comp-cstr-fixnum-p) (comp-cstr-type-p): * lisp/emacs-lisp/comp-run.el (comp-subr-trampoline-install) (native--compile-async): * lisp/emacs-lisp/comp.el (comp--get-function-cstr) (comp--function-pure-p, comp--intern-func-in-ctxt) (comp--addr-to-bb-name, comp--emit-assume, comp--maybe-add-vmvar) (comp--add-call-cstr, comp--compute-dominator-tree) (comp--dom-tree-walker, comp--ssa-rename) (comp--function-call-maybe-fold, comp--fwprop-call) (comp--call-optim-func): * lisp/emacs-lisp/edebug.el (edebug-global-prefix) (edebug-remove-instrumentation): * lisp/emacs-lisp/eieio.el (initialize-instance): * lisp/emacs-lisp/ert-x.el (ert-resource-directory): * lisp/emacs-lisp/ert.el (ert--expand-should-1) (ert-test-location, ert-write-junit-test-report) (ert-test--erts-test): * lisp/emacs-lisp/icons.el (icon-complete-spec, icon-string) (icons--create): * lisp/emacs-lisp/lisp-mode.el (lisp--local-defform-body-p): * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--make-autoload) (loaddefs-generate--parse-file): * lisp/emacs-lisp/multisession.el (multisession-edit-mode--revert, multisession-edit-value): * lisp/emacs-lisp/package-vc.el (package-vc--read-archive-data) (package-vc--version, package-vc--clone): * lisp/emacs-lisp/package.el (package--reload-previously-loaded): * lisp/emacs-lisp/pp.el (pp--insert-lisp): * lisp/emacs-lisp/subr-x.el (add-display-text-property): * lisp/emacs-lisp/tabulated-list.el (tabulated-list-print): * lisp/emacs-lisp/timer.el (run-at-time): * lisp/emacs-lisp/vtable.el (vtable-goto-table) (vtable-goto-column, vtable-update-object, vtable--insert-line) (vtable--compute-widths, vtable--make-keymap): * lisp/emacs-lisp/warnings.el (display-warning): * lisp/epa-file.el (epa-file-insert-file-contents): * lisp/epa.el (epa-show-key): * lisp/erc/erc-backend.el (erc--split-line, erc--conceal-prompt) (PRIVMSG, erc--get-isupport-entry): * lisp/erc/erc-button.el (erc-button-add-nickname-buttons) (erc--button-next): * lisp/erc/erc-common.el (erc--find-group): * lisp/erc/erc-fill.el (erc-fill, erc-fill-static) (erc-fill--wrap-escape-hidden-speaker) (erc-fill--wrap-unmerge-on-date-stamp) (erc-fill--wrap-massage-initial-message-post-clear) (erc-fill-wrap, erc-fill--wrap-rejigger-region): * lisp/erc/erc-goodies.el (erc--scrolltobottom-all) (erc--keep-place-indicator-on-window-buffer-change) (keep-place-indicator, erc--keep-place-indicator-adjust-on-clear) (erc-keep-place-move, erc--command-indicator-display): * lisp/erc/erc-ibuffer.el (erc-members): * lisp/erc/erc-join.el (erc-join--remove-requested-channel) (erc-autojoin--join): * lisp/erc/erc-networks.el (erc-networks--id-qualifying-init-parts, erc-networks--id-reload) (erc-networks--id-ensure-comparable) (erc-networks--reclaim-orphaned-target-buffers) (erc-networks--server-select): * lisp/erc/erc-nicks.el (erc-nicks-invert) (erc-nicks--redirect-face-widget-link, erc-nicks--highlight) (erc-nicks--highlight-button) (erc-nicks--list-faces-help-button-action, erc-nicks-list-faces) (erc-nicks-refresh, erc-nicks--colors-from-faces) (erc-nicks--track-prioritize) (erc-nicks--remember-face-for-track): * lisp/erc/erc-notify.el (querypoll, erc--querypoll-get-next) (erc--querypoll-on-352, erc--querypoll-send): * lisp/erc/erc-sasl.el (erc-sasl--read-password): * lisp/erc/erc-services.el (erc-services-issue-ghost-and-retry-nick): * lisp/erc/erc-speedbar.el (erc-speedbar--ensure, nickbar) (erc-speedbar-toggle-nicknames-window-lock) (erc-speedbar--compose-nicks-face): * lisp/erc/erc-stamp.el (erc-stamp--recover-on-reconnect) (erc-stamp-prefix-log-filter, erc--conceal-prompt) (erc--insert-timestamp-left, erc-insert-timestamp-right) (erc-stamp--defer-date-insertion-on-post-modify) (erc-insert-timestamp-left-and-right) (erc-stamp--redo-right-stamp-post-clear) (erc-stamp--reset-on-clear, erc-stamp--dedupe-date-stamps): * lisp/erc/erc-status-sidebar.el (bufbar) (erc-status-sidebar-prefer-target-as-name) (erc-status-sidebar-default-allsort, erc-status-sidebar-click): * lisp/erc/erc-track.el (erc-track--shortened-names-get) (erc-track--setup, erc-track--select-mode-line-face) (erc-track-modified-channels, erc-track--collect-faces-in) (erc-track--switch-buffer, erc-track--replace-killed-buffer): * lisp/erc/erc-truncate.el (erc-truncate--setup) (erc-truncate-buffer): * lisp/erc/erc.el (erc--ensure-query-member) (erc--ensure-query-members, erc--remove-channel-users-but) (erc--cusr-change-status, erc--find-mode, erc--update-modules) (erc-log-irc-protocol, erc--refresh-prompt) (erc--restore-important-text-props) (erc--order-text-properties-from-hash, erc-send-input-line) (erc-cmd-IGNORE, erc--unignore-user, erc-cmd-QUERY) (erc-cmd-BANLIST, erc--speakerize-nick) (erc--format-speaker-input-message, erc-channel-receive-names) (erc-send-current-line, erc-format-target-and/or-network) (erc-kill-buffer-function, erc-restore-text-properties) (erc--get-eq-comparable-cmd): * lisp/eshell/em-alias.el (eshell-maybe-replace-by-alias--which) (eshell-maybe-replace-by-alias): * lisp/eshell/em-glob.el (eshell-glob-convert): * lisp/eshell/em-pred.el (eshell-pred-user-or-group) (eshell-pred-file-time, eshell-pred-file-type) (eshell-pred-file-mode, eshell-pred-file-links) (eshell-pred-file-size): * lisp/eshell/em-prompt.el (eshell-forward-paragraph) (eshell-next-prompt): * lisp/eshell/esh-arg.el (eshell-resolve-current-argument): * lisp/eshell/esh-cmd.el (eshell-do-eval, eshell/which) (eshell-plain-command--which, eshell-plain-command): * lisp/eshell/esh-io.el (eshell-duplicate-handles) (eshell-protect-handles, eshell-get-target, eshell-close-target): * lisp/eshell/esh-proc.el (eshell-sentinel): * lisp/eshell/esh-var.el (eshell-parse-variable-ref) (eshell-get-variable, eshell-set-variable): * lisp/faces.el (face-at-point): * lisp/ffap.el (ffap-in-project): * lisp/filenotify.el (file-notify--rm-descriptor): * lisp/files-x.el (read-dir-locals-file) (connection-local-update-profile-variables) (connection-local-value): * lisp/files.el (file-remote-p, abbreviate-file-name) (set-auto-mode, hack-local-variables) (revert-buffer-restore-read-only): * lisp/find-dired.el (find-dired-sort-by-filename): * lisp/font-lock.el (font-lock--filter-keywords): * lisp/gnus/gnus-art.el (article-emojize-symbols): * lisp/gnus/gnus-int.el (gnus-close-server): * lisp/gnus/gnus-search.el (gnus-search-transform) (gnus-search-indexed-parse-output, gnus-search-server-to-engine): * lisp/gnus/gnus-sum.el (gnus-collect-urls, gnus-shorten-url): * lisp/gnus/gnus.el (gnus-check-backend-function): * lisp/gnus/message.el (message-send-mail): * lisp/gnus/mml.el (mml-generate-mime, mml-insert-mime-headers): * lisp/gnus/nnatom.el (nnatom--read-feed, nnatom--read-article) (nnatom--read-article-or-group-authors, nnatom--read-publish) (nnatom--read-update, nnatom--read-links): * lisp/gnus/nnfeed.el (nnfeed--read-server, nnfeed--write-server) (nnfeed--parse-feed, nnfeed--group-data, nnfeed-retrieve-article) (nnfeed-retrieve-headers, nnfeed--print-part) (nnfeed-request-article, nnfeed-request-group) (nnfeed-request-list, nnfeed--group-description) (nnfeed-request-group-description) (nnfeed-request-list-newsgroups, nnfeed-request-rename-group): * lisp/gnus/nnmh.el (nnmh-update-gnus-unreads): * lisp/help-fns.el (help-find-source) (help-fns--insert-menu-bindings, help-fns--mention-first-release) (help-fns--mention-shortdoc-groups) (help-fns--customize-variable-version) (help-fns--face-custom-version-info, describe-mode): * lisp/help-mode.el (help-make-xrefs): * lisp/help.el (help-key-description, help--describe-command): * lisp/hfy-cmap.el (htmlfontify-load-rgb-file): * lisp/ibuf-ext.el (ibuffer-jump-to-filter-group) (ibuffer-kill-filter-group, ibuffer-kill-line) (ibuffer-save-filter-groups, ibuffer-save-filters, filename) (basename, file-extension, ibuffer-diff-buffer-with-file-1) (ibuffer-mark-by-file-name-regexp) (ibuffer-mark-by-content-regexp): * lisp/ibuf-macs.el (ibuffer-aif, ibuffer-awhen): * lisp/ibuffer.el (ibuffer-mouse-toggle-mark) (ibuffer-toggle-marks, ibuffer-mark-interactive) (ibuffer-compile-format, process, ibuffer-map-lines): * lisp/image.el (image--compute-map) (image--compute-original-map): * lisp/image/exif.el (exif-parse-buffer): * lisp/image/image-converter.el (image-convert-p, image-convert) (image-converter--find-converter): * lisp/image/image-dired-util.el (image-dired-file-name-at-point): * lisp/image/image-dired.el (image-dired-track-original-file) (image-dired--on-file-in-dired-buffer) (image-dired--with-thumbnail-buffer) (image-dired-jump-original-dired-buffer) (image-dired--slideshow-step, image-dired-display-image): * lisp/image/wallpaper.el (wallpaper--init-action-kill) (wallpaper--find-setter, wallpaper--find-command) (wallpaper--find-command-args, wallpaper--x-monitor-name): * lisp/info-look.el (info-lookup-interactive-arguments) (info-complete)::(:mode): * lisp/info.el (info-pop-to-buffer, Info-read-node-name-1): * lisp/international/emoji.el (emoji--adjust-displayable-1) (emoji--add-recent): * lisp/jsonrpc.el (jsonrpc--call-deferred) (jsonrpc--process-sentinel, jsonrpc--remove): * lisp/keymap.el (keymap-local-lookup): * lisp/mail/emacsbug.el (report-emacs-bug-hook) (submit-emacs-patch): * lisp/mail/ietf-drums.el (ietf-drums-parse-addresses): * lisp/mail/mailclient.el (mailclient-send-it): * lisp/mail/rfc6068.el (rfc6068-parse-mailto-url): * lisp/mail/undigest.el (rmail-digest-parse-mixed-mime): * lisp/minibuffer.el (completion-metadata-get) (completions--after-change) (minibuffer-visible-completions--filter): * lisp/net/browse-url.el (browse-url-url-at-point) (browse-url-file-url, browse-url-emacs): * lisp/net/dbus.el (dbus-byte-array-to-string) (dbus-monitor-goto-serial): * lisp/net/dictionary.el (dictionary-search): * lisp/net/eww.el (eww--download-directory) (eww-auto-rename-buffer, eww-open-in-new-buffer, eww-submit) (eww-follow-link, eww-read-alternate-url) (eww-copy-alternate-url): * lisp/net/goto-addr.el (goto-address-at-point): * lisp/net/mailcap.el (mailcap-mime-info): * lisp/net/rcirc.el (rcirc, rcirc-connect, rcirc-send-string) (rcirc-kill-buffer-hook, rcirc-print, rcirc-when) (rcirc-color-attributes, rcirc-handler-NICK) (rcirc-handler-TAGMSG, rcirc-handler-BATCH): * lisp/net/shr.el (shr-descend, shr-adaptive-fill-function) (shr-correct-dom-case, shr-tag-a): * lisp/net/sieve.el (sieve-manage-quit): * lisp/outline.el (outline-cycle-buffer): * lisp/pcmpl-git.el (pcmpl-git--tracked-file-predicate): * lisp/proced.el (proced-auto-update-timer): * lisp/progmodes/bug-reference.el (bug-reference-try-setup-from-vc): * lisp/progmodes/c-ts-common.el (c-ts-common--fill-paragraph): * lisp/progmodes/c-ts-mode.el (c-ts-mode--preproc-offset) (c-ts-mode--anchor-prev-sibling, c-ts-mode-indent-defun): * lisp/progmodes/compile.el (compilation-error-properties) (compilation-find-file-1): * lisp/progmodes/eglot.el (eglot--check-object) (eglot--read-server, eglot-upgrade-eglot) (eglot-handle-notification, eglot--CompletionParams) (eglot-completion-at-point, eglot--sig-info) (eglot-register-capability): * lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile-and-load) (elisp-eldoc-var-docstring-with-value): * lisp/progmodes/erts-mode.el (erts-mode--goto-start-of-test): * lisp/progmodes/flymake.el (flymake--update-eol-overlays) (flymake-eldoc-function): * lisp/progmodes/gdb-mi.el (gdb-breakpoints-list-handler-custom) (gdb-frame-handler): * lisp/progmodes/go-ts-mode.el (go-ts-mode-docstring) (go-ts-mode--comment-on-previous-line-p) (go-ts-mode--get-test-regexp-at-point) (go-ts-mode-test-this-file): * lisp/progmodes/grep.el (lgrep, rgrep-default-command) (grep-file-at-point): * lisp/progmodes/perl-mode.el (perl--end-of-format-p): * lisp/progmodes/php-ts-mode.el (php-ts-mode--anchor-prev-sibling, php-ts-mode--indent-defun): * lisp/progmodes/project.el (project--other-place-command) (project--find-default-from, project--transplant-file-name) (project-prefixed-buffer-name, project--remove-from-project-list) (project-prompt-project-name, project-remember-projects-under) (project--switch-project-command) (project-uniquify-dirname-transform, project-mode-line-format): * lisp/progmodes/python.el (python-font-lock-keywords-maximum-decoration) (python--treesit-fontify-union-types) (python-shell-get-process-name, python-shell-restart) (python-shell-completion-at-point, python-ffap-module-path) (python-util-comint-end-of-output-p, python--import-sources) (python-add-import, python-remove-import, python-fix-imports): * lisp/progmodes/xref.el (xref--add-log-current-defun): * lisp/repeat.el (repeat-echo-message-string): * lisp/saveplace.el (save-place-dired-hook): * lisp/server.el (server-save-buffers-kill-terminal): * lisp/shadowfile.el (shadow-make-fullname) (shadow-contract-file-name, shadow-define-literal-group): * lisp/shell.el (shell-highlight-undef-mode): * lisp/simple.el (command-completion-using-modes-p) (command-execute, file-user-uid, file-group-gid) (first-completion, last-completion, switch-to-completions): * lisp/startup.el (startup--load-user-init-file): * lisp/tab-line.el (tab-line-tabs-buffer-group-by-project): * lisp/tar-mode.el (tar-goto-file, tar-next-file-displayer): * lisp/term/android-win.el (android-encode-select-string) (gui-backend-set-selection): * lisp/term/haiku-win.el (haiku-dnd-convert-string) (haiku-select-encode-xstring, haiku-select-encode-utf-8-string): * lisp/textmodes/emacs-news-mode.el (emacs-news--buttonize): * lisp/textmodes/ispell.el (ispell-completion-at-point): * lisp/textmodes/sgml-mode.el (sgml-validate) (html-mode--complete-at-point): * lisp/textmodes/tex-mode.el (tex-recenter-output-buffer) (xref-backend-references): * lisp/thingatpt.el (thing-at-point-file-at-point) (thing-at-point-face-at-point): * lisp/thread.el (thread-list--get-status): * lisp/time.el (world-clock-copy-time-as-kill, world-clock): * lisp/touch-screen.el (touch-screen-handle-touch): * lisp/treesit.el (treesit-language-at, treesit-node-at) (treesit-node-on, treesit-buffer-root-node) (treesit-node-field-name, treesit-local-parsers-at) (treesit-local-parsers-on, treesit--cleanup-local-range-overlays) (treesit-font-lock-recompute-features) (treesit-font-lock-fontify-region, treesit-transpose-sexps) (treesit-add-log-current-defun, treesit-major-mode-setup) (treesit--explorer-refresh, treesit-install-language-grammar): * lisp/url/url.el (url-retrieve-synchronously): * lisp/vc/smerge-mode.el (smerge-diff): * lisp/vc/vc-dir.el (vc-dir): * lisp/vc/vc-dispatcher.el (vc-do-async-command): * lisp/vc/vc-git.el (vc-git-dir--branch-headers) (vc-git-dir--stash-headers, vc-git--log-edit-summary-check) (vc-git-stash-list): * lisp/vc/vc.el (vc-responsible-backend, vc-buffer-sync-fileset) (vc-clone): * lisp/visual-wrap.el (visual-wrap--apply-to-line): * lisp/wid-edit.el (widget-text) (widget-editable-list-insert-before): * lisp/window-tool-bar.el (window-tool-bar--keymap-entry-to-string): * lisp/window.el (display-buffer, display-buffer-full-frame) (window-point-context-set, window-point-context-use) (window-point-context-use-default-function): * lisp/xdg.el (xdg-current-desktop): * lisp/xwidget.el (xwidget-webkit-callback): * lisp/yank-media.el (yank-media--get-selection) (yank-media-types): * test/lisp/comint-tests.el (comint-tests/test-password-function): * test/lisp/completion-preview-tests.el (completion-preview-tests--capf): * test/lisp/cus-edit-tests.el (with-cus-edit-test): * test/lisp/erc/erc-scenarios-base-local-modules.el (-phony-sblm-): * test/lisp/erc/erc-scenarios-stamp.el (erc-scenarios-stamp--on-post-modify): * test/lisp/erc/erc-services-tests.el (erc-services-tests--asp-parse-entry): * test/lisp/erc/erc-tests.el (erc-modules--internal-property) (erc--find-mode, erc-tests--update-modules): * test/lisp/erc/resources/erc-d/erc-d-i.el (erc-d-i--parse-message): * test/lisp/erc/resources/erc-d/erc-d-t.el (erc-d-t-kill-related-buffers, erc-d-t-with-cleanup): * test/lisp/erc/resources/erc-d/erc-d-tests.el (erc-d-i--parse-message--irc-parser-tests): * test/lisp/erc/resources/erc-d/erc-d-u.el (erc-d-u--read-exchange-slowly): * test/lisp/erc/resources/erc-d/erc-d.el (erc-d--expire) (erc-d--finalize-done, erc-d--command-handle-all): * test/lisp/erc/resources/erc-scenarios-common.el (erc-scenarios-common-with-cleanup): * test/lisp/erc/resources/erc-tests-common.el (erc-tests--common-display-message) (erc-tests-common-create-subprocess): * test/lisp/ibuffer-tests.el (ibuffer-test-Bug25058): * test/lisp/international/mule-tests.el (mule-cmds-tests--ucs-names-missing-names): * test/lisp/progmodes/python-tests.el (python-tests-get-shell-interpreter) (python-tests--get-interpreter-info): * test/lisp/progmodes/ruby-ts-mode-tests.el (ruby-ts-resource-file): * test/lisp/replace-tests.el (replace-tests-with-undo): * test/src/emacs-tests.el (emacs-tests--seccomp-debug): * test/src/process-tests.el (process-tests--emacs-command) (process-tests--emacs-binary, process-tests--dump-file): * test/src/treesit-tests.el (treesit--ert-test-defun-navigation): Replace use of the now-obsolete if-let and when-let.
* Don't autoload erc-modulesF. Jason Park2024-10-181-2/+0
| | | | | | | | | | | | | * doc/misc/erc.texi (Modules): Recommend using `describe-variable' instead of `customize-option' because the latter needs the symbol to be loaded. * lisp/erc/erc.el (erc-modules): Remove autoload cookie because it caused customizations for this option to load the main library. This reverts the thrust of bb894845 "Teach customize-option about erc-modules", which was added in ERC 5.6 and Emacs 30. The motivation for the original offending change was to allow new users to run M-x customize-option RET erc-modules RET immediately after startup instead of M-x customize-group RET, followed by an I-search. (Bug#73812)
* Don't create directory in erc-truncate compat checkF. Jason Park2024-10-111-0/+2
| | | | | | | | | | | | | | | | | * lisp/erc/erc-log.el (erc-log--check-writable-nocreate-p): New variable. (erc-logging-enabled): Use `erc-log--save-in-progress-p' flag to conditionally avoid creating a directory when checking if the location is writable. (erc-log--call-when-logging-enabled-sans-module) (erc-log--check-legacy-implicit-enabling-by-truncate): Rename former to latter, and guard against creating a ~/log directory just to see if it's writable when calling `erc-logging-enabled'. (erc-truncate-mode): Explain legacy "implicit logging" behavior in doc string. * lisp/erc/erc-truncate.el (erc-truncate--warn-about-logging): Make more concise, and defer to `erc-truncate-mode' doc string for particulars. * lisp/erc/erc.el (erc-directory-writable-p): Add comment to rename on next non-patch release.
* Prefer defcustom :local specifierStefan Kangas2024-10-041-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/dirtrack.el (dirtrack-list): * lisp/emacs-lisp/lisp.el (defun-prompt-regexp): * lisp/emulation/viper-init.el (viper-related-files-and-buffers-ring): * lisp/emulation/viper-util.el (viper-syntax-preference): * lisp/erc/erc.el (erc-ignore-list): * lisp/files.el (buffer-offer-save, backup-by-copying-when-mismatch): * lisp/find-file.el (ff-pre-find-hook, ff-pre-load-hook) (ff-post-load-hook, ff-not-found-hook, ff-file-created-hook) (ff-case-fold-search, ff-always-in-other-window) (ff-ignore-include, ff-quiet-mode, ff-other-file-alist) (ff-search-directories): * lisp/mh-e/mh-e.el (mh-scan-prog): * lisp/newcomment.el (comment-column): * lisp/obsolete/rlogin.el (rlogin-directory-tracking-mode): * lisp/play/decipher.el (decipher-ignore-spaces): * lisp/plstore.el (plstore-encrypt-to): * lisp/proced.el (proced-format, proced-filter, proced-sort) (proced-descend, proced-auto-update-flag, proced-tree-flag): * lisp/progmodes/fortran.el (fortran-line-length): * lisp/shell.el (shell-history-file-name): * lisp/simple.el (goal-column, fill-prefix): * lisp/vc/ediff-init.el (ediff-use-faces) (ediff-highlight-all-diffs, ediff-autostore-merges): * lisp/vc/ediff-merg.el (ediff-show-clashes-only) (ediff-skip-merge-regions-that-differ-from-default): Prefer defcustom :local specifier to using 'make-variable-buffer-local' directly.
* Redo ERC truncation and /CLEAR hook mechanismF. Jason Park2024-09-291-11/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: Mention option `erc-truncate-padding-size'. * lisp/erc/erc-fill.el (erc-fill-wrap-mode, erc-fill-wrap-enable) (erc-fill-wrap-disable): Manage membership in the `erc--clear-function' advice stack for own function that massages a buffer's oldest inserted message, post truncation. (erc-fill--wrap-massage-initial-message-post-clear): New function. * lisp/erc/erc-log.el (erc-log-mode, erc-log-enable): Don't add `erc-save-buffer-in-logs' to `erc--pre-clear-functions'. Use local advice around common interface variable instead, as noted below. (erc-log-disable): Likewise, don't remove `erc-save-buffer-in-logs' from `erc--pre-clear-functions'. (erc-log-setup-logging): Add `erc-log--save-on-clear' to `erc--clear-function'. (erc-log-disable-logging): Remove `erc-log--save-on-clear' to `erc-clear-function'. (erc-save-buffer-in-logs): Abort when `erc--insert-marker' is non-nil. (erc-log--save-on-clear): New function, a thin wrapper around `erc-save-buffer-in-logs', adapting it to the `erc--clear-function' advice interface. * lisp/erc/erc-stamp.el (erc-stamp-mode, erc-stamp-enable): Don't add `erc-stamp--reset-on-clear' to `erc--pre-clear-functions'. (erc-stamp-disable): Don't remove `erc-stamp--reset-on-clear' from `erc--pre-clear-functions'. (erc-stamp--find-insertion-point): Account for initial position being `bobp'. (erc-stamp--defer-date-insertion-on-post-modify): Accommodate the rare non-list `erc-insert-post-hook' when shadowing. (erc-stamp--setup): Add and remove `erc-stamp--reset-on-clear' to and from `erc--clear-function' advice stack. (erc-stamp--redo-right-stamp-post-clear): New function. (erc-stamp--update-saved-position): Remove unused function. This was originally added along with `erc-stamp--reset-on-clear' as part of bug#60936. (erc-stamp--reset-on-clear): Expect end of truncation boundary to be at `erc-insert-marker'. Rework to use new `erc--clear-function' interface and run on `erc-timer-hook' instead of `erc-insert-done-hook'. * lisp/erc/erc-truncate.el (erc-truncate-padding-size): New option to help tamp down on disruptions when reading scroll back caused by overly frequent truncation. (erc-truncate-enable, erc-truncate-disable): Add and remove `erc-truncate--setup' to and from `erc-mode-hook', and run it when needed. (erc-truncate--buffer-size): New variable. (erc-truncate--setup): New function. (erc-truncate-buffer-to-size): Guard execution with `erc-truncate--padding-size' and `erc--inhibit-clear-p'. Reflow for readability, removing obsolete comments. Call hooks with marker instead of buffer position, as per the new `erc--clear-function' interface. (erc-truncate-buffer): Defer execution to `erc-timer-hook' when running post-insertion via a response handler. (erc-truncate--inhibit-when-local-and-interactive): New function. * lisp/erc/erc.el (erc-mode): Add `erc--skip-past-headroom-on-clear' to `erc--clear-function' in all ERC buffers. (erc--with-spliced-insertion): Account for marker being `bobp'. (erc--insert-before-markers-transplanting-hidden): Make more robust by accommodating initial `point' possibly being `bobp'. (erc--clear-function): New variable, a function-valued local-advice interface to replace `erc--pre-clear-functions'. (erc--pre-clear-functions): Remove unused variable. (erc--skip-past-headroom-on-clear): New function. (erc--inhibit-clear-p): New variable. (erc-cmd-CLEAR): Call hooks with markers instead of position. Signal `user-error' when `erc--inhbiit-clear-p' is non-nil. * test/lisp/erc/erc-scenarios-log.el (erc-scenarios-log--clear-stamp) (erc-scenarios-log--cmd-clear/date-stamps): Rename former to latter, update assertions, and use common helper. (erc-scenarios-log--cmd-clear/left-stamps): New test. (erc-scenarios-log--truncate): Move body to function of the same name, and update assertions. (erc-scenarios-log--truncate/left-stamps): New test. (Bug#72736)
* Fix overlooked case in erc--get-inserted-msg-beg-atF. Jason Park2024-09-291-6/+10
| | | | | | | | | | | | | * lisp/erc/erc.el (erc--get-inserted-msg-beg-at): Account for the start of a props header being `bobp' when searching backwards. (erc--get-inserted-msg-prop): Add optional `point' parameter. * test/lisp/erc/erc-goodies-tests.el (erc--get-inserted-msg-beg/truncated/readonly): New test. * test/lisp/erc/erc-tests.el (erc--get-inserted-msg-beg/truncated): New test. * test/lisp/erc/resources/erc-tests-common.el (erc-tests-common-assert-get-inserted-msg/truncated): New test helper. (Bug#72736)
* Improve inconsistent handling of ban lists in ERCF. Jason Park2024-09-291-93/+122
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: Mention new function `erc-sync-banlist' in new section for ERC 5.6.1. * lisp/erc/erc-backend.el (erc-server-MODE): Don't call `erc-banlist-update'. * lisp/erc/erc-fill.el (erc--determine-fill-column-function): New method for `fill' and `fill-wrap' modules. * lisp/erc/erc-pcomplete.el (pcomplete/erc-mode/BANLIST) (pcomplete/erc-mode/BL) (pcomplete/erc-mode/MASSUNBAN, pcomplete/erc-mode/MUB): New functions. * lisp/erc/erc.el: Map ERC 5.6.1 to Emacs 31.1 in `customize-package-emacs-version-alist'. (erc-channel-banlist): Deprecate practice of using the symbol property `received-from-server' of as a state flag because it's error-prone and bleeds into other connections. (erc--channel-banlist-synchronized-p): New variable to indicate whether the ban list has been initialized. The presence of a local binding for `erc-channel-banlist' could probably be used for the same purpose but would surely require rewriting `erc-cmd-BANLIST' and `erc-cmd-MASSUNBAN'. (erc-sync-banlist): New function, announced in ERC-NEWS. (erc--wrap-banlist-cmd): New function. (erc-banlist-fill-padding): New variable. (erc--determine-fill-column-function): New generic function. (erc-cmd-BANLIST): Move forward declaration of `erc-fill-column' from top level into function body. Always reset `received-from-server' to nil. Improve column calculations. (erc-cmd-MASSUNBAN): Always reset `received-from-server' to nil. (erc-banlist-finished): Deprecate function unused since 2003. (erc--banlist-update): New function. (erc-banlist-update): Deprecate function because its logic is faulty and it doesn't handle mixed mode letters, like "MODE #foobar +mb *@127.0.0.1". See https://modern.ircdocs.horse/#mode-message. It also depends on an obsolete convention regarding the symbol property `received-from-server' of `erc-channel-banlist'. Basically, this function used to run upon receipt of any "MODE" command from the server. However, actual updates to the variable `erc-channel-banlist' only happened if `received-from-server' was t, which could only be the case after the user issued a /MASSUNBAN. And that behavior was determined to be a bug. This mode framework stuff was introduced as part of bug#67220 for ERC 5.6. (erc--handle-channel-mode): New function, a method for standard channel-mode letter "b". * test/lisp/erc/erc-tests.el (erc--channel-modes) (erc--channel-modes/graphic-p): Assert contents of `erc-channel-banlist' updated on "MODE". (Bug#72736)
* Store one string per user in erc--spkr msg propF. Jason Park2024-09-291-15/+14
| | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc.el (erc--msg-props): Mention that the `erc--spkr' msg-prop value is taken from the `nickname' slot of the user's `erc-server-users' entry. (erc--speakerize-nick): Avoid using the provided NICK parameter for the `erc--spkr' property. Instead, use the version from the `nickname' slot of its `erc-server-users' item, which is itself an `erc-server-user' object. These text props were originally introduced in ERC 5.6 as part of bug#67677. * test/lisp/erc/erc-tests.el (erc--refresh-prompt) (erc--check-prompt-input-functions, erc-send-current-line) (erc--check-prompt-input-for-multiline-blanks) (erc-send-whitespace-lines): Use more convenient helper utility to create fake server buffer where possible. (erc--speakerize-nick): New test. * test/lisp/erc/resources/erc-tests-common.el (erc-tests-common-make-server-buf): Don't use ERT temp buffer's name for dialed server, etc., because it contains unwanted chars. (erc-tests-common-with-process-input-spy): Defer to each test to set up its own prompt, etc. (Bug#72736)
* Merge from savannah/emacs-30Po Lu2024-08-131-4/+4
|\ | | | | | | | | | | | | b585826a65e ; * lisp/files.el (require-with-check): Fix doc string an... 6d55e94996e macOS: Wrong frame rectangle after wake (bug#71912) c49724b9649 ; Grammar fixes 5c3d340e001 Fix format 2 cmap handling in sfnt.c
| * ; Grammar fixesPo Lu2024-08-121-4/+4
| | | | | | | | | | | | | | | | * doc/misc/erc.texi (Connecting): * lisp/erc/erc.el (erc-compute-server, erc-compute-nick) (erc-compute-full-name, erc-compute-port): Replace "a number of increasingly more" with an alternative more grammatical.
* | Merge from origin/emacs-30Eli Zaretskii2024-07-131-2/+1
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | a6c78ccf5f2 ; * src/w32fns.c (Fw32_notification_close): Fix typo (bug... febafe37884 * test/lisp/wdired-tests.el (wdired-test-bug34915): Fix f... 846b79b6d02 Fix 'wdired-test-unfinished-edit-01' bc154cba130 ; * src/search.c (Fre_search_forward): Clarify doc string... 53291e3d46e Fontify destructor in c++-ts-mode d77f8a34750 Fix invalid defcustom type for erc-buffers option d68a4ea3ec6 ; Fix 'ibuffer-do-isearch{-regexp}' 8b1a0f8695a Fix infloop in 'shell-resync-dirs' ce13eee5ab7 ; * src/image.c (free_image_cache): Add assertion. (Bug#...
| * Fix invalid defcustom type for erc-buffers optionF. Jason Park2024-07-121-2/+1
| | | | | | | | | | | | | | * lisp/erc/erc.el (erc-ensure-target-buffer-on-privmsg): Change invalid inner `choice' to a `const' for the third-state `status' variant, which is new in ERC 5.6 and Emacs 30. Thanks to Mattias Engdegård for catching this.
* | Merge from savannah/emacs-30Po Lu2024-07-091-6/+6
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dce31372a60 editorconfig-core-handle.el: Fix regressions in fnmatch h... ed2986494c7 Checkdoc fixes in `url/*.el` 846c0e10ffa Checkdoc fixes in `term/*.el` 3977aa07568 Checkdoc fixes in `mh-e/*.el` 521f740d013 Checkdoc fixes in `calc/*.el` 336aa6ab17a Checkdoc fixes in `textmodes/*.el` e19fd6a22de Checkdoc fixes in `gnus/*.el` 7350457c793 Checkdoc fixes in `eshell/*.el` 23c1ba81ddd Checkdoc fixes in `emulation/*.el` c85f67a66df Checkdoc fixes in `erc/*.el` e392382e2e2 Checkdoc fixes in `vc/*.el` ef7364b070e Checkdoc fixes in `emacs-lisp/*.el` 5fe1ae0e843 Checkdoc fixes in `mail/*.el` e43e9d09986 Checkdoc fixes in `net/*.el` 4c6e9f5b004 Improve `use-package-vc-valid-keywords` docstring format 928180f32be ; * etc/TODO: New item on installing Magit. c193a702dc2 ; Improve a recent change to the documentation 6ebc5d5c278 ; Delete fixed item from etc/TODO: "proced on macOS" 7b2778e3a3d ; Delete fixed NS bug from etc/TODO 84552ff395c Revert "Fix link to major mode variable in docstring" 198063ba643 * etc/TODO: Add item to convert documentation to 'setopt'. 92de67829ca Prefer 'setopt' in browse-url docs 76683853905 ; Improve 'native-comp-debug' documentation
| * Checkdoc fixes in `erc/*.el`Stefan Kangas2024-07-081-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc-backend.el (erc-server-parameters): * lisp/erc/erc-button.el (erc-button--display-error-with-buttons): * lisp/erc/erc-dcc.el (erc-dcc-member): * lisp/erc/erc-fill.el (erc-fill-wrap-refill-buffer): * lisp/erc/erc-speedbar.el (erc-speedbar--last-ran): * lisp/erc/erc-stamp.el (erc-stamp--current-time): * lisp/erc/erc-track.el (erc-make-mode-line-buffer-name): * lisp/erc/erc.el (erc-interactive-display, erc-modules, erc-cmd-CLEAR) (erc-update-current-channel-member, erc--format-user-modes) (erc-check-text-conversion): Checkdoc fixes.
| * Change ERC version for Emacs 30 to 5.6.0.30.1F. Jason Park2024-06-271-2/+2
| | | | | | | | | | | | | | | | | | * doc/misc/erc.texi: Change ERCVER to 5.6.0.30.1. * lisp/erc/erc.el: Change Version package header to 5.6.0.30.1. Don't bother updating the `customize-package-emacs-version-alist' entry because no user options are yet affected. (erc-version): Change version to 5.6.0.30.1. Do not merge to master.
* | Change ERC version to 5.6.1-gitF. Jason Park2024-06-271-2/+2
|/ | | | | | | * doc/misc/erc.texi: Change ERCVER to 5.6.1. * lisp/erc/erc.el: (erc-version): Change working version to 5.6.1-git. Do the same for the package Version header. Don't bother updating `customize-package-emacs-version-alist' until needed.
* Release ERC 5.6F. Jason Park2024-06-121-2/+2
| | | | | | | | | | * lisp/erc/erc.el: Change Version header from 5.6-git to 5.6. A `customize-package-emacs-version-alist' mapping for ERC 5.6 to Emacs 30.1 was already added when moving from 5.5 to 5.6-git. The ERCVER variable in doc/misc/erc.texi was likewise updated at that time. Going forward, such changes will continue to happen preemptively, on the flip side of each release. (erc-version): Change version from 5.6-git to 5.6.
* ; Amend some doc strings in ERCF. Jason Park2024-06-121-4/+5
| | | | | | | | | * lisp/erc/erc-backend.el (define-erc-response-handler): Mention important distinction between aliases for handlers and hooks, and note expected type for the latter. * lisp/erc/erc.el (erc--define-channel-user-status-compat-getter): Mention that these accessors are not inlined like those generated by `cl-defstruct'.
* ; Improve erc-format-privmessage documentationF. Jason Park2024-06-081-3/+11
| | | | | | | | * etc/ERC-NEWS: Mention that `erc-format-privmessage' has been removed from the default client's primary code path. Revise various headlines. * lisp/erc/erc.el: Bump Compat version to 29.1.4.5. (erc-format-privmessage): Make appeal for users to contact the mailing list if they need to modify speaker-message formatting.
* Don't recurse in erc-server-delayed-check-reconnectF. Jason Park2024-06-051-9/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc-backend.el (erc-server-delayed-check-reconnect): Run `reschedule' function on a timer to avoid growing the stack when calling `delete-process'. * lisp/erc/erc-common.el (erc--favor-changed-reverted-modules-state): Fix `pcase' condition so that changing an option to its standard value does not earn a "STANDARD" label in Customize if that value differs from the saved one. * lisp/erc/erc.el (erc-open-socks-tls-stream): Reword doc string. * test/lisp/erc/erc-tests.el (erc--with-dependent-type-match) (erc--with-dependent-type-match): Remove useless tests (bug#71178). * test/lisp/erc/resources/base/reconnect/unexpected-disconnect.eld: Await phantom EOFs and PINGs to somewhat account for a race that can result in a failure when running the suite in parallel with -jN. * test/lisp/erc/resources/erc-scenarios-common.el (erc-scenarios-common--print-trace): Set `debug-on-error' to t so that errors in timers always trigger test failures. ;; * test/lisp/erc/resources/base/assoc/reconplay/foonet.eld: ;; Timeouts. ;; * test/lisp/erc/resources/base/upstream-reconnect/soju-barnet.eld: ;; Timeouts. ;; * test/lisp/erc/resources/base/mask-target-routing/foonet.eld: ;; Timeouts. ;; * test/lisp/erc/resources/join/network-id/barnet.eld: Timeout.
* Add ERC module querypoll as monitor placeholderF. Jason Park2024-05-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/misc/erc.texi: Add module `querypoll' to list of built-in modules'. * etc/ERC-NEWS: Mention new module `querypoll', and explain new default behavior for deriving query membership from that of channels. * lisp/erc/erc-goodies.el (erc--querypoll-ring) (erc--querypoll-timer): New variables. (erc-querypoll-exclude-regexp): New option. (erc-querypoll-mode, erc-querypoll-enable, erc-querypoll-disable): New module for polling with "WHO" requests for the presence of otherwise "untracked" query targets. (erc-querypoll-period-params): New variable. (erc--querypoll-compute-period) (erc--querypoll-target-in-chan-p) (erc--querypoll-get-length) (erc--querypoll-get-next) (erc--querypoll-subscribe) (erc--querypoll-on-352) (erc--querypoll-send): New functions. * lisp/erc/erc-speedbar.el (erc-speedbar-buttons): Dispatch queries as if they were channels when `erc--queries-current-p' returns non-nil. That is, show head counts alongside query targets as users come and go. (erc-speedbar-insert-target): Defer to `erc--queries-current-p' to know whether to show a query in the style of a channel. This affects both the plain speedbar integration as well as the `nickbar' module added for bug#63595. Also, use question marks rather than the empty string for query bullets, so that query and channel items are aligned vertically. * lisp/erc/erc.el (erc--queries-current-p): New function. * test/lisp/erc/erc-goodies-tests.el (erc--querypoll-compute-period) (erc--querypoll-target-in-chan-p) (erc--querypoll-get-length) (erc--querypoll-get-next): New tests. (Bug#70928)
* Retain client's own user in erc-server-usersF. Jason Park2024-05-271-35/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc-backend.el (erc-server-KICK, erc-server-PART): Use new function `erc--remove-channel-user-but' instead of `erc-remove-channel-users'. In `erc-server-KICK', remove sender's channel membership data after displaying the message so that nicks are buttonized. Return nil. In `erc-server-PART', don't run `erc-remove-channel-member' when the client itself has parted. * lisp/erc/erc-common.el (erc--remove-user-from-targets): New function. * lisp/erc/erc.el (erc-remove-server-user): Redo doc string. (erc--forget-server-user-function): New variable. (erc--forget-server-user): New function. (erc--forget-server-user-ignoring-queries): New function, the default value of `erc--forget-server-user-function'. (erc-remove-channel-user): Defer to `erc--forget-server-user-function' to do the actual removal. (erc-remove-user): Defer to `erc--remove-user-from-targets'. (erc-remove-channel-users): Redo doc (erc--remove-channel-users-but): New function. The only use case thus far is for protecting the client's own `erc-server-users' entry from removal when draining `erc-channel-members' tables after the client leaves a target buffer or quits. (erc-kill-buffer-function): Don't remove own user from `erc-server-users'. * test/lisp/erc/erc-scenarios-base-renick.el (erc-scenarios-base-renick-queries-solo): Assert own client parting its only channel doesn't remove own user from server. Also assert that another user parting their only channel removes them from all queries. (Bug#70928)
* Tether query rolls to channel membership in ERCF. Jason Park2024-05-271-4/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc-backend.el (erc-server-JOIN): Update query membership via `erc--ensure-query-member' when someone else joins a channel. (erc-server-NICK): Update query membership via `erc--ensure-query-member' after someone else changes their nick. (erc-server-PRIVMSG): After printing a query message from some other person, remove their nick's data from the query buffer's user table if they're "untracked," i.e., not a member of a channel. (erc-server-263, erc-server-263-functions): New function and variable, a default response handler and hook for "RPL_TRYAGAIN", which servers send for things like rejecting "WHO" and "WHOX" responses due to rate limiting. (erc-server-311): Fix call to `erc-update-user-nick' so the userhost login component is no longer supplied as the `info' parameter but rather, correctly, as the `login'. (erc--extract-352-full-name): Factor out trailing hop-count and GECOS parsing for use by overriding handlers or those for adjacent numerics. (erc-server-352): Refactor to handle asterisk as `channel' parameter, which indicates a nick rather than a channel target. (erc-server-366): Update membership in all query buffers via `erc--ensure-query-members' after all names have been received. (erc-server-401): Forget a known user completely when the server reports them as nonexistent. * lisp/erc/erc-common.el (erc--get-server-user): New function, a thin wrapper around `erc-get-server-user' for cases were inlining would require declaring symbols not defined in erc-common. * lisp/erc/erc.el (erc-channel-members): Mention that instances are used for query-participant tables as well. (erc--decouple-query-and-channel-membership-p): New variable, a compatibility flag to access pre-5.6 query bookkeeping behavior. (erc--ensure-query-member, erc--ensure-query-members): New functions. (erc-cmd-QUERY): Ensure parties are present in the query buffer's membership table if they're known to be on the server by simple virtue of being present in some joined channel. (erc-message-english-s352-you): New variable. * test/lisp/erc/erc-scenarios-base-query-participants.el (erc-scenarios-base-query-participants) (erc-scenarios-base-query-participants/legacy): Rename former to latter. Enable compat flag to activate legacy query behavior in which channel membership does not impact query membership. (erc-scenarios-base-query-participants/coupled): New test asserting new behavior in which channel membership dictates query membership. (Bug#70928)
* Reuse old query buffers for reassumed nicks in ERCF. Jason Park2024-05-271-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc-backend.el (erc--wrangle-query-buffers-on-nick-change): New function for handling buffer renaming and message routing triggered by a nick change. Such twiddling used to reside in `erc-server-NICK' but has been separated out for use by built-in modules overriding `erc-server-NICK'. The behavior has also changed to favor always reusing an existing query buffer whenever possible instead of creating a new, <N>-suffixed buffer. This addresses some arguably unfinished business from bug#48598. (erc-server-NICK): Fix erroneous call to `erc-update-user-nick' that passed the sender's login as the function's INFO argument. Move buffer renaming logic to `erc--wrangle-query-buffers-on-nick-change' for use by "NICK" handlers managed by modules. Also, print the notice in all query buffers when the client changes its own nick. (erc-server-QUIT): Show messages in all query buffers when the client itself quits, but prevent `track' from updating the mode line with redundant noise. * lisp/erc/erc.el (erc-generate-new-buffer-name): Fix typo in doc. (erc--query-list): New function. * test/lisp/erc/erc-scenarios-base-query-participants.el: New file. * test/lisp/erc/erc-scenarios-base-renick.el (erc-scenarios-base-renick-queries-solo): Revise slightly to use modern helper API. (erc-scenarios-base-renick-queries/reassume): New test. (erc-scenarios-base-renick-self/merge-query): New test. * test/lisp/erc/resources/base/query-participants/legacy.eld: New file. * test/lisp/erc/resources/base/reconnect/options-again.eld: Adjust timeout. * test/lisp/erc/resources/base/renick/queries/reassume.eld: New file. * test/lisp/erc/resources/base/renick/self/manual.eld: Update timeouts. * test/lisp/erc/resources/base/renick/self/merge-query-a.eld: New file. * test/lisp/erc/resources/base/renick/self/merge-query-b.eld: New file. (Bug#70928)
* Return nil from more ERC response handlersF. Jason Park2024-05-271-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: Mention that certain aberrant response handlers now return nil. * lisp/erc/erc-backend.el (define-erc-response-handler): Mention that body should explicitly return nil. (erc-server-PART) (erc-server-PING): Return nil. * lisp/erc/erc-sasl.el (erc-sasl--destroy): Return nil. * lisp/erc/erc.el (erc-display-message): Mention in doc string that the return value is undefined. (erc-kill-channel-hook): Fix package-version. * test/lisp/erc/erc-networks-tests.el (erc-networks--set-name): Ensure `erc--route-insertion' returns nil because this influences whether response-handler hooks continue running. * test/lisp/erc/erc-sasl-tests.el (erc-sasl-create-client-ecdsa): Fix regression that made test unusable, although it's still relatively useless and therefore skipped by default. * test/lisp/erc/erc-services-tests.el (erc-services-tests--auth-source-standard) (erc-services-tests--auth-source-announced): Clarify annotations. * test/lisp/erc/erc-tests.el (erc-message): Don't return non-nil in mocked `erc-display-message'. (erc-send-modify-hook): Shadow `erc-send-modify-hook' because `erc-stamp--date-mode' modifies it locally.
* Reconcile erc-stamp--date-stamps when merging buffersF. Jason Park2024-05-181-3/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: Mention new face `erc-information'. * lisp/erc/erc-button.el (erc-button-add-buttons): Skip buttonization when the "msg prop" `erc--skip' is present and contains the symbol `button'. Set `alist' to nil in the same guard condition as a roundabout way of suppressing further processing. * lisp/erc/erc-networks.el (erc--insert-admin-message): Forward declaration. (erc-networks--insert-transplanted-content) (erc-networks--transplant-buffer-content): Replace former with latter. Change signature to take source and destination buffers as parameters. (erc-networks--transplant-target-buffer-function): New function-valued variable. (erc-networks--target-transplant-in-progress-p): New variable, a flag for downstream code to detect when a transplant is underway. (erc-networks--reclaim-orphaned-target-buffers): Defer to `erc-networks--transplant-target-buffer-function' to handle the actual transplant business. Crucially, kill the buffer afterwards instead of beforehand. If new buffer-association bugs emerge related to the combining of old or renamed target buffers, this reordering may be at fault. (erc-networks--copy-over-server-buffer-contents): Pass old and new buffers to `erc-networks--insert-transplanted-content'. * lisp/erc/erc-stamp.el (erc-stamp--defer-date-insertion-on-post-modify): Set `fn' slot of `erc-stamp--date' instance to `ignore' when running the actual callback in order to conserve a little space. (erc-stamp--date-mode): Add and remove hook members for `erc-networks--copy-server-buffer-functions' and `erc-networks--transplant-target-buffer-function'. (erc-insert-timestamp-left-and-right): Always clear `erc-timestamp-last-inserted-right' to ensure a right stamp accompanies every date stamp. (erc-stamp--dedupe-date-stamps) (erc-stamp--dedupe-date-stamps-from-buffer) (erc-stamp--dedupe-date-stamps-from-target-buffer): New functions. Date stamp behavior was revamped as part of bug#60936. * lisp/erc/erc.el (erc-informational): New face. (erc--insert-admin-message): New function to hide some "msg prop" complexity from "upstream" libraries, like `erc-networks', and thus avoid more forward-declarations. A less smelly approach would be to devise a general interface owned by such libraries, or erc-common, that `erc-mode' could then hook into on init. (erc-display-message-highlight): Make face matching more limber to accommodate the convention of face names lacking a "-face" suffix. (erc-message-english-graft): New variable. (erc-kill-channel): Inhibit execution of hook when `erc-networks--target-transplant-in-progress-p' is non-nil. * test/lisp/erc/erc-networks-tests.el (erc-networks--rename-server-buffer--no-existing--orphan) (erc-networks--rename-server-buffer--existing--reuse) (erc-networks--rename-server-buffer--local-match) (erc-networks--rename-server-buffer--local-nomatch): Use helper to initialize markers. * test/lisp/erc/erc-stamp-tests.el (erc-stamp--dedupe-date-stamps): New test. (Bug#70928)
* Don't kill server buffer with erc-kill-buffer-on-partF. Jason Park2024-05-181-11/+21
| | | | | | | | | | | | | | | | | | | | | | | | | * etc/ERC-NEWS: Mention new flag `erc-killing-buffer-on-part-p' and the renaming of `erc-kill-channel'. * lisp/erc/erc-backend.el (erc-server-PART): Only kill a buffer on behalf of `erc-kill-buffer-on-part' when the buffer hasn't already been killed, and bind `erc-killing-buffer-on-part-p' to t when doing so. * lisp/erc/erc-log.el (erc-conditional-save-buffer): Don't save logs when the buffer parameter is nil because that causes the server buffer to be saved out. It's possible that user code relying on this longstanding bug will be affected, however, by default, the server buffer will also be saved out independently at designated junctures. * lisp/erc/erc.el (erc-part-hook): Redo doc string. (erc-killing-buffer-on-part-p): New variable, a flag to prevent redundant execution of `erc-kill-channel-hook' members concerned with parted channels. (erc-kill-buffer-on-part): Tweak doc string. (erc-kill-channel-hook): Use new name for `erc-kill-channel', `erc-part-channel-on-kill'. (erc-kill-channel, erc-part-channel-on-kill): Rename former to latter, and inhibit execution when `erc-killing-buffer-on-part-p' is non-nil. * test/lisp/erc/erc-scenarios-base-kill-on-part.el: New file. (Bug#70840)
* Avoid shared-ref read syntax in ERC message catalogsF. Jason Park2024-05-081-12/+13
| | | | | | | | * lisp/erc/erc.el (erc--message-speaker-ctcp-action-input) (erc--message-speaker-ctcp-action-statusmsg-input): Don't use shared/circular references, like #1=foo ... #1#, in literal strings because it triggers CI validation failures. These message-format definitions were originally introduced as part of bug#67677.
* Add format-catalog entry for unknown chan mode in ERCF. Jason Park2024-05-081-1/+2
| | | | | | | | | | | | | | | | | | | | | | * lisp/erc/erc.el (erc--process-channel-modes): Use format spec catalog entry, and convert char to string. (erc-message-english-channel-mode-unknown): New variable. ;; * test/lisp/erc/erc-scenarios-base-renick.el ;; (erc-scenarios-base-renick-queries-solo): Adjust timeout. ;; * test/lisp/erc/erc-scenarios-ignore.el (erc-scenarios-ignore/basic): ;; Adjust timeouts. ;; * test/lisp/erc/erc-scenarios-misc.el (erc-scenarios-base-flood): ;; Adjust timeouts. ;; * test/lisp/erc/resources/base/assoc/bouncer-history/barnet.eld: ;; Adjust timeouts. ;; * test/lisp/erc/resources/base/reuse-buffers/channel/barnet.eld: ;; Adjust timeouts. ;; * test/lisp/erc/resources/erc-d/erc-d-tests.el (erc-d-run-basic): ;; Adjust timeouts. ;; * test/lisp/erc/resources/sasl/plain.eld: Adjust timeouts. ;; * test/lisp/erc/resources/sasl/external.eld: Adjust timeout. ;; * test/lisp/erc/resources/base/auth-source/foonet.eld: Adjust ;; timeout.
* ; Set explicit hook depth for erc-once-with-server-eventF. Jason Park2024-05-021-1/+1
| | | | | | | | | | | * lisp/erc/erc.el (erc-once-with-server-event): Set hook depth to -95. * test/lisp/erc/erc-scenarios-base-association-nick.el: Improve comment. * test/lisp/erc/resources/erc-d/erc-d-tests.el (erc-d--render-entries): Remove do-nothing assertion since its purpose was unclear and likely dubious, as was incidentally highlighted by the addition of a function not present on older Emacsen, which this test still needs to run on.
* Fix regression involving erc-query-buffer-pF. Jason Park2024-04-191-3/+8
| | | | | | | | | | | * lisp/erc/erc.el (erc-server-or-unjoined-channel-buffer-p): Doc. (erc-query-buffer-p): Don't return non-nil in non-ERC buffers and server buffers, and continue to honor string arguments. The regression was introduced by 3d87e343 "Use modern fallback for channel name detection in ERC". Thanks to Libera user mekeor for reporting this bug. * test/lisp/erc/erc-tests.el (erc-query-buffer-p): New test. (Bug#67220)