Fix icalendar export

master
Jacopo De Simoi 2 years ago
parent 597f2f6322
commit f43116752a
  1. 25
      global.org

@ -2027,11 +2027,34 @@
(org-narrow-to-subtree)
(let ((org-icalendar-scheduled-summary-prefix "")
(org-icalendar-use-scheduled '(event-if-todo))
(org-icalendar-include-todo) nil)
(org-icalendar-include-todo nil))
(shell-command (concat "~/scripts/push-to-nextcloud-cal.sh "
(org-icalendar-export-to-ics))))
(widen))
#+end_src
*** Make reftex work in org-edit
RefTeχ refuses to work when the buffer is not visiting a file.
Here is a tentative workaround:
- extract the file we are tangling to
- use it as TeX-master
- hijack ~buffer-file-name~ to return something non-nil; I would
rather hijack it locally (using cl-letf rather than advising the
function since other things would be confused by the advice)
#+begin_src emacs-lisp
(defun hijack-buffer-file-name (orig-fun &rest args)
(if (not (boundp 'reftex-workaround-enabled))
(apply orig-fun args)
(cl-letf (((symbol-function 'buffer-file-name) (lambda (&optional buffer) "fragment.tex")))
(apply orig-fun args))))
(advice-add 'reftex-label :around
#'hijack-buffer-file-name)
(advice-add 'reftex-reference :around
#'hijack-buffer-file-name)
#+end_src
** elisp
*** Paredit
#+begin_src emacs-lisp

Loading…
Cancel
Save