Commit graph

4494 commits

Author SHA1 Message Date
Eric Abrahamsen
bb28f8b9d1 Make sure Gnus search groups search topics recursively
* lisp/gnus/gnus-group.el (gnus-group-make-search-group,
gnus-group-read-ephemeral-search-group): If a search is initiated from
a topic line, make sure we get all the groups under that topic (and
under sub-topics).
2020-11-13 17:25:46 -08:00
Stefan Kangas
206dd9d592 Don't quote lambdas in several places
* lisp/allout-widgets.el (allout-widgets-adjusting-message)
(allout-widgets-exposure-change-processor)
(allout-widgets-count-buttons-in-region):
* lisp/ansi-color.el (ansi-color-make-color-map):
* lisp/case-table.el (describe-buffer-case-table):
* lisp/emacs-lisp/byte-opt.el (byte-decompile-bytecode-1):
* lisp/gnus/gnus-agent.el (gnus-agent-regenerate-group):
* lisp/gnus/nnir.el (nnir-run-swish++, nnir-run-swish-e)
(nnir-run-hyrex, nnir-run-namazu):
* lisp/hippie-exp.el (make-hippie-expand-function)
(try-complete-lisp-symbol, try-complete-lisp-symbol-partially)
(try-expand-all-abbrevs):
* lisp/international/mule-cmds.el (sort-coding-systems)
(select-safe-coding-system, select-message-coding-system)
(read-language-name, encoded-string-description):
* lisp/international/quail.el (quail-keyseq-translate)
(quail-get-translations, quail-build-decode-map)
(quail-insert-decode-map):
* lisp/jka-compr.el (jka-compr-uninstall):
* lisp/locate.el (locate-in-alternate-database):
* lisp/mail/mailabbrev.el (mail-resolve-all-aliases-1)
(mail-abbrev-make-syntax-table):
* lisp/mh-e/mh-seq.el (mh-read-folder-sequences):
* lisp/net/eudcb-ldap.el (eudc-ldap-simple-query-internal):
* lisp/progmodes/make-mode.el (makefile-query-targets)
(makefile-prompt-for-gmake-funargs):
* lisp/shadowfile.el (shadow-cancel, shadow-shadows-of):
* lisp/sort.el (sort-pages, sort-fields, sort-regexp-fields):
* lisp/subr.el (listify-key-sequence):
* lisp/term/wyse50.el (terminal-init-wyse50):
* lisp/textmodes/ispell.el (ispell-help)
(ispell-begin-tex-skip-regexp):
* lisp/textmodes/page-ext.el (pages-sort-region):
* lisp/textmodes/refer.el (refer-find-entry-in-file):
* lisp/url/url-expand.el (url-expand-file-name): Don't quote lambdas.
2020-11-12 22:24:58 +01:00
Eric Abrahamsen
3e07b871c4 Remove unused "internal" gnus-search variables
* lisp/gnus/gnus-search.el (gnus-search-memo-query,
gnus-search-memo-server): No longer needed.
2020-11-11 10:36:51 -08:00
Eric Abrahamsen
d22a914c79 Fix defgeneric name of gnus-search-index(ed)-extract
* lisp/gnus/gnus-search.el (gnus-search-indexed-extract): Had the
wrong name on the generic.
2020-11-11 10:35:20 -08:00
Andrew G Cohen
ee11a68320 Remove ephemeral group on error or null result
* lisp/gnus/nnselect.el (nnselect-request-group): If an ephemeral
group is empty, there is nothing to see, so remove the group.
(nnselect-run): Catch and return an empty artlist on error.
2020-11-10 08:19:43 +08:00
Eric Abrahamsen
795b7da16b Add more protections to gnus-search query parsing
* lisp/gnus/gnus-group.el (gnus-group-make-search-group,
gnus-group-read-ephemeral-search-group): If the query is coming in via
the old 'nnir-query-spec key, we know not to parse it.
* lisp/gnus/gnus-search.el (gnus-search-make-query-string): Check if
the query was sent in as '(query "query"), and not '(query . "query).
(gnus-search-imap-search-keys): Add x-gm-raw to imap search keys.
(gnus-search-prepare-query): If we know this query should be raw,
don't even try parsing it, as it probably won't work.
2020-11-08 16:35:19 -08:00
Eric Abrahamsen
33c7ddd47d Another backwards-compatibility fix for gnus-search
* lisp/gnus/gnus-search.el (gnus-search-server-to-engine): Because of
the way we've set up the obsolete variable alias for
`nnir-method-default-engines', we may end up with its value in
`gnus-search-default-engines'. Make the check for "old style" values
general, so we catch them no matter where they came from.
2020-11-08 08:39:19 -08:00
Eric Abrahamsen
35d9881809 Various fixes and backward compatibility for gnus-search
* lisp/gnus/gnus-group.el (gnus-group-make-search-group,
gnus-group-read-ephemeral-search-group): Check for and accept the old
nnir-* spec keys.
* lisp/gnus/gnus-search.el (shared-initialize): Use
generate-new-buffer instead of doing it ourselves.
(gnus-search-server-to-engine): Raise an informative error explicitly
if we can't find a search engine, rather than letting it fall through
to something less helpful.
(gnus-search-make-spec): Add `gnus-search--complete-key-data' to
`completion-at-point-functions' locally, not globally.
2020-11-07 09:44:10 -08:00
Mattias Engdegård
b7b9bbb93d Rectify skip-set argument
* lisp/gnus/gnus-search.el (gnus-search-query-end-of-input):
Remove brackets that don't belong.  Found by relint.
2020-11-06 23:02:29 +01:00
Mattias Engdegård
aea936562b * lisp/gnus/gnus-search.el (gnus-search-contact-tables): Fix type.
A more precise type is desirable but at it is now correct ('list' is not).
2020-11-06 13:55:33 +01:00
Eric Abrahamsen
ac471ff09d Fixes and improvements to gnus-search
* lisp/gnus/gnus-search.el (gnus-search-default-engines): Change type
from a list of two-element lists, to alist. This matches nnir's old
option type, and should make transition easier.
(nnir-imap-default-search-key): Note that variable is obsolete.
(gnus-search-transform-expression): Interpret the "attachment" key as
"body" in imap searches. Allow specifying larger/smaller message size
values in KB or MB units.
(gnus-search-server-to-engine): Fix error in this function, and
clarify somewhat.
2020-11-05 19:47:58 -08:00
Eric Abrahamsen
125956725b Avoid use of eieio-oset-default
* lisp/gnus/gnus-search.el: Replace with an :initform tag on the slot
definition. `symbol-value' is necessary, otherwise the defclass macro
will treat the option as a quoted symbol.
2020-11-04 10:40:25 -08:00
Stefan Monnier
a63d905175 Fix misuses of make-local-variable on hooks
* lisp/vc/smerge-mode.el (smerge-ediff):
* lisp/progmodes/python.el (python-pdbtrack-setup-tracking):
* lisp/net/tramp-smb.el (tramp-smb-call-winexe):
* lisp/net/secrets.el (secrets-mode):
* lisp/mail/rmail.el (rmail-variables):
* lisp/ielm.el (inferior-emacs-lisp-mode):
* lisp/erc/erc-log.el (erc-log-setup-logging): Use `add-hook`.

* lisp/eshell/em-unix.el (eshell/diff):
* lisp/eshell/em-hist.el (eshell-hist-initialize): Don't
`make-local-variable` on hooks.
2020-11-04 00:24:45 -05:00
Eric Abrahamsen
9bcdebd9b7 Remove gmane search engine
Remove the gnus-search-gmane class and all associated methods.  If
search functionality is ever resurrected, then revert this commit.

* lisp/gnus/gnus-search.el: Delete code, and remove from default value
of `gnus-search-default-engines'.
2020-11-03 21:20:17 -08:00
Eric Abrahamsen
0328b21d1e Move nnir.el to lisp/obsolete
* lisp/obsolete/nnir.el: This is no longer used, but users might still
be requiring it.
2020-11-03 21:20:17 -08:00
Eric Abrahamsen
7fad12c59b New gnus-search library
This library provides a fundamental reworking of the search
functionality previously found in nnir.el.  It uses class-based search
engines to interface with external searching facilities, and a parsed
search query syntax that can search multiple engines.

* lisp/gnus/gnus-search.el: New library containing search
functionality for Gnus.
* doc/misc/gnus.texi: Document.
* lisp/gnus/gnus-group.el (gnus-group-make-search-group,
gnus-group-read-ephemeral-search-group): Remove references to nnir,
change meaning of prefix argument, change values of nnselect-function
and nnselect-args.
* lisp/gnus/nnselect.el: Replace references to nnir
(nnselect-request-article): Use gnus-search functions, and search
criteria.
(nnselect-request-thread, nnselect-search-thread): Use gnus-search
thread search.
(gnus-summary-make-search-group): Switch to use gnus-search function
and arguments.
* test/lisp/gnus/search-tests.el: Tests for new functionality.
2020-11-03 21:20:17 -08:00
Lars Ingebrigtsen
ada9b7c9ce Tweak previous article-treat-ansi-sequences fix
* lisp/gnus/gnus-art.el (article-treat-ansi-sequences): Redo the
previous fix to avoid a compilation warning (bug#44299).
2020-10-29 12:38:13 +01:00
Andreas Schwab
8cd0ce9b85 Don't spill ansi-color across parts in articles
* lisp/gnus/gnus-art.el (article-treat-ansi-sequences): Reset
ansi-color-context-region.  (Bug#44299)
2020-10-29 10:21:17 +01:00
Lars Ingebrigtsen
f1bf89e383 Make gnus-output-to-rmail appending work better
* lisp/gnus/gnus-util.el (gnus-output-to-rmail): Ensure we have a
blank line before the next line when using mbox format (bug#39580).
2020-10-27 19:29:02 +01:00
Lars Ingebrigtsen
35df337979 Fix syntax error in message-add-openpgp-header
* lisp/gnus/message.el (message-add-openpgp-header): Remove
redundant (and syntactically wrong) check.
2020-10-25 15:16:05 +01:00
Stefan Kangas
6c58d90042 Make more load-hooks obsolete (Bug#21563)
* lisp/progmodes/dcl-mode.el (dcl-mode):
* lisp/progmodes/idlw-complete-structtag.el: Recommend
with-eval-after-load instead of load-hooks.
* lisp/calc/calc-ext.el (calc-ext-load-hook):
* lisp/emacs-lisp/bytecomp.el (bytecomp-load-hook):
* lisp/emacs-lisp/cl-extra.el (cl-extra-load-hook):
* lisp/emacs-lisp/cl-macs.el (cl-macs-load-hook):
* lisp/emacs-lisp/cl-seq.el (cl-seq-load-hook):
* lisp/gnus/message.el (message-load-hook):
* lisp/gnus/nnheader.el (nnheader-load-hook):
* lisp/gnus/nnmail.el (nnmail-load-hook):
* lisp/progmodes/dcl-mode.el (dcl-mode-load-hook):
* lisp/textmodes/tex-mode.el (tex-mode-load-hook):
* lisp/whitespace.el (whitespace-load-hook): Obsolete for
with-eval-after-load.  Note that these variables are never declared,
but the byte-compiler will still warn about them if used.
2020-10-20 19:14:04 +02:00
Lars Ingebrigtsen
d96734729d Fix up smiley emoji application to make it reversible
* lisp/gnus/smiley.el (smiley-region): Use text properties for the
emojis instead of rewriting the message.
2020-10-18 09:42:25 +02:00
Adam Sjøgren
9907912624 Add support for emojis i smiley.el
* lisp/gnus/smiley.el (smiley-style): Add emoji
tag.
(smiley-emoji-regexp-alist): New defcustom.
(smiley-update-cache, smiley-region): Support emoji (non-image)
replacement (bug#43889).
2020-10-18 09:36:43 +02:00
Lars Ingebrigtsen
96d7e3dcaf Fix previous gnus-icalendar sanitization
* lisp/gnus/gnus-icalendar.el (gnus-icalendar-event-from-ical):
Fix previous change -- respect nil values passed in.
2020-10-16 10:46:14 +02:00
Lars Ingebrigtsen
95d0b71683 Sanitize ical data in gnus-icalendar-event-from-ical
* lisp/gnus/gnus-icalendar.el (gnus-icalendar-event-from-ical):
Sanitise the data before passing it on to the constructor.  This
avoids backtraces on icals with extra, unknown slots (bug#43057).
2020-10-16 10:16:31 +02:00
Lars Ingebrigtsen
41d220dc60 Add a new variable to control Gnus Agent caching
* doc/misc/gnus.texi (Agent Variables): Document it.

* lisp/gnus/gnus-art.el (gnus-request-article-this-buffer): Ditto.

* lisp/gnus/gnus-async.el (gnus-async-article-callback): Use it.

* lisp/gnus/gnus.el (gnus-agent-eagerly-store-articles): New variable.

Includes work from Madhu <enometh@meer.net>.
2020-10-16 07:21:05 +02:00
Lars Ingebrigtsen
a38002cecd Make Gnus more liberal when interpreting Face headers again
* lisp/gnus/gnus-fun.el (gnus-convert-face-to-png): Do it.

* lisp/gnus/gnus-util.el (gnus-base64-repad): Allow not checking
anything, but just repadding.
2020-10-15 08:39:00 +02:00
Paul Eggert
b058caca72 nnimap MODSEQ cleanup
* lisp/gnus/nnimap.el (nnimap-parse-flags):
Remove old hack that deletes MODSEQ entries in the buffer, as
Emacs now has bignums and so won't misparse MODSEQs (Bug#38938).
2020-10-13 10:25:40 -07:00
Lars Ingebrigtsen
85e81721ea message-insert-signature doc fix
* lisp/gnus/message.el (message-insert-signature): Clarify what
FORCE means.
2020-10-13 03:17:12 +02:00
Rasmus
e8fcc14f28 gnus-icalendar.el: Fix bug in gnus-icalendar-identities
* lisp/gnus/gnus-icalendar.el (gnus-icalendar-event--find-attendee):
(gnus-icalendar-identities) `gnus-ignored-from-addresses' and
`message-alternative-emails' may be functions. This is not
supported by `gnus-icalendar-event--find-attendee' (bug#43908).
2020-10-10 22:32:41 +02:00
Lars Ingebrigtsen
e45b0c5d94 message-signature doc fix
* lisp/gnus/message.el (message-signature): Mention
message-signature-insert-empty-line (bug#43853).
2020-10-09 06:48:51 +02:00
Lars Ingebrigtsen
e2ece08273 Revert "Don't eagerly store articles in the Agent by default"
This reverts commit def34a2076.

This made storing articles in the Agent very slow.
2020-10-09 06:26:17 +02:00
Juri Linkov
7301bf996e Use … in Gnus mode lines (when shortening them)
* lisp/gnus/gnus-sum.el (gnus-set-mode-line): Defer ellipsis
creation to `truncate-string-to-width' (bug#41250).  This uses …
by default.
2020-10-05 09:01:03 +02:00
Stefan Kangas
ceae38b933 ; Fix trivial typos in ChangeLogs 2020-10-03 12:53:51 +02:00
Glenn Morris
726eb835dd Merge from origin/emacs-27
78eacf31e8 ; Fix many typos in symbols in docs and comments
d5d12707d6 * doc/misc/flymake.texi (Using Flymake): Fix a typo.  (Bug...

# Conflicts:
#	lisp/allout.el
#	lisp/progmodes/ebrowse.el
2020-10-02 09:38:24 -07:00
Stefan Kangas
78eacf31e8 ; Fix many typos in symbols in docs and comments 2020-10-02 13:29:45 +02:00
Robert Pluim
9b47ae2304 Don't error if no GPG signing key configured
* lisp/gnus/mml-sec.el (mml-secure-epg-sign): Partially revert
"Make mml-secure-epg-sign bug out if we can't find an identity".
It causes signing to fail for people who have not set up
mml-secure-{smime,openpgp}-sign-with-sender, which is a regression
from Emacs-26 (Bug#40118).  In such a situation gpg will use its
default key.

Do not merge to master. On master Emacs will query the user.
2020-10-02 10:47:23 +02:00
Stefan Kangas
c6fa0ad315 ; Prefer https to http in many URLs
These were all tested with https and confirmed working.
2020-10-01 15:28:15 +02:00
Lars Ingebrigtsen
26a8821250 Make mml-sec-tests not hang waiting for input
* lisp/gnus/mml-sec.el (mml-secure-epg-sign): Only query if we're
running interactively.  This makes a test not hang.
2020-10-01 05:17:01 +02:00
Alex Bochannek
d11627a7ca Make gnus-base64-repad a bit stricter again
* lisp/gnus/gnus-util.el (gnus-base64-repad): Make the code a bit
stricter again.
2020-10-01 02:44:58 +02:00
Robert Pluim
7518596857 Query for the signer when sending signed mail (with unknown signer)
* lisp/gnus/mml-sec.el (mml-secure-sender-sign-query): New
function (bug#40118).
(mml-secure-epg-sign): Use it to determine the signer (bug#40118).

* lisp/gnus/mml-sec.el
(mml-secure-allow-signing-with-unknown-recipient): Remove.
2020-10-01 02:14:17 +02:00
Lars Ingebrigtsen
fcdcdea324 Fix whitespace regexp in gnus-base64-repad
* lisp/gnus/gnus-util.el (gnus-base64-repad): Fix the whitespace
regexp.
2020-09-30 05:05:09 +02:00
Lars Ingebrigtsen
da40e5ecd7 Fix space parsing in gnus-base64-repad
* lisp/gnus/gnus-util.el (gnus-base64-repad): Get the separator
regexp right -- there will often be spaces around the newlines.
2020-09-29 15:36:46 +02:00
Mattias Engdegård
511c9d02b7 * lisp/gnus/smime.el (smime-openssl-program): Allow nil value. 2020-09-29 12:33:50 +02:00
Alex Bochannek
eaf224f88d Repad the Face header in Gnus
* lisp/gnus/gnus-fun.el (gnus-convert-face-to-png): Use it.

* lisp/gnus/gnus-util.el (gnus-base64-repad): New function (bug#43441).
2020-09-28 14:09:07 +02:00
Jan Tatarik
232382415d Fix Gnus parsing of weekly recurring icalendar events
* lisp/gnus/gnus-icalendar.el
(gnus-icalendar-event:recurring-interval): Fix parsing of weekly
recurring events (bug#43669).

Example: in the absence of explicit INTERVAL value in the calendar
event, a weekly event with occurrences scheduled for Mondays and
Wednesdays should receive the default recurring interval of "1" and the
org mode timestamp repeater should be "+1w".

Due to a bug in the current code we receive "WEEKLY" and "+WEEKLYw"
instead. The patch fixes the issue.
2020-09-28 13:08:37 +02:00
Lars Ingebrigtsen
20da487d8b message-add-action doc string fix
* lisp/gnus/message.el (message-add-action): Document types.
2020-09-26 17:33:08 +02:00
Lars Ingebrigtsen
e1c33e29d5 Fix some defcustom types
* lisp/whitespace.el (whitespace-style):
* lisp/gnus/message.el (message-screenshot-command):
* lisp/progmodes/compile.el (compilation-transform-file-match-alist):
* lisp/progmodes/gdb-mi.el (gdb-default-window-configuration-file):
* lisp/progmodes/python.el (python-pdbtrack-exit-command): Fix the
defcustom types.
* lisp/progmodes/sql.el (sql-password-wallet): Fix the value.
2020-09-25 15:15:21 +02:00
dickmao
5df652d614 Add sanity check for Gnus groups that belong to no topic
* lisp/gnus/gnus-topic.el (gnus-topic-change-level): Do not change
gnus-topic-alist when group is outside "topology" (bug#43582).
2020-09-24 16:49:15 +02:00
Eric Abrahamsen
e542b4b785 Write Gnus active files with quotes around group names
* lisp/gnus/gnus-util.el (gnus-write-active-file): In case of group
names with spaces in them (see Bug#42823). Names are later read with
`read', so this should be quite robust.
2020-09-23 16:01:38 -07:00