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

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

[nongnu] elpa/org-auto-tangle 15884227bb 16/56: got it working again by


From: ELPA Syncer
Subject: [nongnu] elpa/org-auto-tangle 15884227bb 16/56: got it working again by moving the hook to inner block
Date: Mon, 6 Jun 2022 11:58:52 -0400 (EDT)

branch: elpa/org-auto-tangle
commit 15884227bbd667c158ad3c5e55e87698bae92c51
Author: Unknown <domatropic@localhost.localdomain>
Commit: Unknown <domatropic@localhost.localdomain>

    got it working again by moving the hook to inner block
---
 org-auto-tangle.el | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/org-auto-tangle.el b/org-auto-tangle.el
index 2391f0e925..c99b84ea12 100644
--- a/org-auto-tangle.el
+++ b/org-auto-tangle.el
@@ -83,14 +83,13 @@
   "Automatically tangle org-mode files with the option #+auto_tangle: t."
   :lighter "org-auto-tangle"
 
-  (add-hook 'org-mode-hook
-            (lambda ()
-             (when org-auto-tangle-mode
-               (add-hook 'after-save-hook
-                         (lambda () (when (and (org-auto-tangle-find-value 
(current-buffer))
-                                               (not (string= 
(org-auto-tangle-find-value(current-buffer)) "nil")))
-                                       (org-auto-tangle-async 
(buffer-file-name))))
-                         nil 'local)))))
+  (when org-auto-tangle-mode
+    (add-hook 'org-mode-hook
+             (add-hook 'after-save-hook
+                       (lambda () (when (and (org-auto-tangle-find-value 
(current-buffer))
+                                             (not (string= 
(org-auto-tangle-find-value(current-buffer)) "nil")))
+                                    (org-auto-tangle-async 
(buffer-file-name)))))
+             nil 'local)))
 
 (provide 'org-auto-tangle)
 



reply via email to

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