Skip to content

Commit

Permalink
fix: workaround org-drill bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jschaf committed Dec 22, 2015
1 parent 7743e3e commit 263a0f1
Showing 1 changed file with 22 additions and 2 deletions.
24 changes: 22 additions & 2 deletions spacemacs-layers/joe/packages.el
Original file line number Diff line number Diff line change
Expand Up @@ -203,9 +203,29 @@ If FORCE is non-nil, force recompilation even if files haven't changed."
)))
(my:replace-or-add-to-alist 'org-publish-project-alist project))
(joe/set-leader-keys
"cs" 'swift-plaques-compile)
"cs" 'swift-plaques-compile))

)
(defun my:work-around-org-window-drill-bug ()
"Comment out a troublesome line in `org-toggle-latex-fragment'.
See
https://bitbucket.org/eeeickythump/org-drill/issues/30/random-blank-buffer-2
for details."
(save-excursion
(let ((org-library-location (concat (locate-library "org" 'nosuffix) ".el") ))
(with-current-buffer
(find-file-noselect org-library-location)
(goto-char (point-min))
(search-forward "(set-window-start nil window-start)")
(back-to-indentation)
(if (looking-at ";; ")
(message "Already modified `org-toggle-latex-fragment' for `org-drill'")
(insert ";; ")
(save-buffer)
(byte-compile-file org-library-location)
(elisp--eval-defun)
(message "Modified `org-toggle-latex-fragment' for `org-drill'"))))))

(my:work-around-org-window-drill-bug)

(defun my:make-org-link-cite-key-visible (&rest _)
"Make the org-ref cite link visible in descriptive links."
Expand Down

0 comments on commit 263a0f1

Please sign in to comment.