I have the following in my init.el file:

(defun my::with-no-drawer (func &rest args)
    (interactive "P")
    (let ((org-log-into-drawer (car args)))  
      (funcall-interactively func args)))

  (advice-add 'org-add-note :around #'my::with-no-drawer)

The idea is that if I do M-x org-add-note then org-log-into-drawer is nil and so the note is added in the main body of the TODO item, but if I do C-u M-x org-add-note then the note would be added to the LOGBOOK drawer.

This works fine in Linux and macOS systems, but has no effect in a Windows installation (the note is always placed in the drawer).

Any idea why? The init.el is identical across all systems.

  • Is the Emacs version older on the Windows computer? – InHarmsWay Feb 8 '18 at 17:33
  • The Emacs on the Windows computer is newer, 27.0.50 (build 1, x86_64-w64-mingw32. – SamanGh Feb 9 '18 at 9:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.