Re: [PATCH] emacs: Respect `load-prefer-newer` when loading `notmuch-init-file'
David Edmondson writes: > On Sunday, 2020-05-31 at 23:17:04 -07, Sean Whitton wrote: > >> 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. > > Reviewed-by: David Edmondson > >> --- pushed. d ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch
Re: [PATCH] emacs: Respect `load-prefer-newer` when loading `notmuch-init-file'
On Sunday, 2020-05-31 at 23:17:04 -07, Sean Whitton wrote: > 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. Reviewed-by: David Edmondson > --- > 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 > > ___ > notmuch mailing list > notmuch@notmuchmail.org > https://notmuchmail.org/mailman/listinfo/notmuch dme. -- I went starin' out of my window, been caught doin' it once or twice. ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch
[PATCH] emacs: Respect `load-prefer-newer` when loading `notmuch-init-file'
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 ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch