emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/org e22b4eb7aa: org-mode: Make local variables effectiv


From: ELPA Syncer
Subject: [elpa] externals/org e22b4eb7aa: org-mode: Make local variables effective during Org startup
Date: Sun, 31 Jul 2022 06:57:41 -0400 (EDT)

branch: externals/org
commit e22b4eb7aab9668826dc8ba76ea1d1d7b144a856
Author: Ihor Radchenko <yantar92@gmail.com>
Commit: Ihor Radchenko <yantar92@gmail.com>

    org-mode: Make local variables effective during Org startup
    
    * lisp/org.el (org-mode): Call `hack-local-variables' early during Org
    mode startup.  This way, Org startup options will regard local
    variable settings.
    
    * testing/.dir-locals.el: Create a stub dir-locals file to prevent
    tests from being affected by directory-local settings of the root Org
    repo folder.
    
    Fixes
    https://list.orgmode.org/587be554-906c-5370-2cf2-f08b14fa58ff@gmail.com/T/#u
---
 lisp/org.el            | 4 ++++
 testing/.dir-locals.el | 5 +++++
 2 files changed, 9 insertions(+)

diff --git a/lisp/org.el b/lisp/org.el
index 3aa8072fc8..2146523641 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -4708,6 +4708,10 @@ The following commands are available:
 
 \\{org-mode-map}"
   (setq-local org-mode-loading t)
+  ;; Apply file-local and directory-local variables, so that Org
+  ;; startup respects them.  See
+  ;; 
https://list.orgmode.org/587be554-906c-5370-2cf2-f08b14fa58ff@gmail.com/T/#u
+  (hack-local-variables 'ignore-mode-settings)
   (org-load-modules-maybe)
   (org-install-agenda-files-menu)
   (when (and org-link-descriptive
diff --git a/testing/.dir-locals.el b/testing/.dir-locals.el
new file mode 100644
index 0000000000..6c957fc64a
--- /dev/null
+++ b/testing/.dir-locals.el
@@ -0,0 +1,5 @@
+;;; Directory Local Variables
+;;; For more information see (info "(emacs) Directory Variables")
+
+;; Stub directory-local file to avoid tests being affected by upper-level 
settings.
+



reply via email to

[Prev in Thread] Current Thread [Next in Thread]