From: Sean Whitton <spwhitton@spwhitton.name>
To: notmuch@notmuchmail.org
Subject: [PATCH] emacs: Respect `load-prefer-newer` when loading `notmuch-init-file'
Date: Sun, 31 May 2020 23:17:04 -0700 [thread overview]
Message-ID: <20200601061704.24071-1-spwhitton@spwhitton.name> (raw)
Before this change, `load-prefer-newer' was ignored.
Set NOERROR and MUST-SUFFIX arguments of `load' to t, and NOSUFFIX
argument to nil, to preserve the behaviour of the deleted `let' form.
---
I've observed that the way that the code at the end of notmuch.el
loads the user's notmuch-init-file means that the variable
load-prefer-newer is effectively ignored: notmuch.el will always load
notmuch-config.elc in preference to notmuch-config.el, even if the
latter is newer than the former. This patch should fix the problem
without changing anything else.
emacs/notmuch.el | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/emacs/notmuch.el b/emacs/notmuch.el
index a980c7a2..5a24d8a7 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -1148,8 +1148,6 @@ beginning of the line."
;; After provide to avoid loops if notmuch was require'd via notmuch-init-file.
(if init-file-user ; don't load init file if the -q option was used.
- (let ((init-file (locate-file notmuch-init-file '("/")
- (get-load-suffixes))))
- (if init-file (load init-file nil t t))))
+ (load notmuch-init-file t t nil t))
;;; notmuch.el ends here
--
2.26.2
next reply other threads:[~2020-06-01 6:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-01 6:17 Sean Whitton [this message]
2020-06-01 8:16 ` [PATCH] emacs: Respect `load-prefer-newer` when loading `notmuch-init-file' David Edmondson
2020-06-01 10:59 ` David Bremner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200601061704.24071-1-spwhitton@spwhitton.name \
--to=spwhitton@spwhitton.name \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).