another hack to get ~/x/notes/z/ to be more usable: add string descriptor

This commit is contained in:
bth 2024-07-01 11:19:54 -07:00
commit cd69c9af55

View file

@ -205,14 +205,14 @@ NOTE: this searches in the current project root only.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; shell integration ;; shell integration
(defun um-next-file-shell (dir &optional header) (defun um-next-file-shell (dir &optional descriptor header)
"Calls um next in the provided dir. "Calls um next in the provided dir.
With the option not to leave behind the um-journal-header. With the option not to leave behind the um-journal-header.
" "
(let ((default-directory dir)) (let ((default-directory dir))
;; https://emacs.stackexchange.com/a/19878 ;; https://emacs.stackexchange.com/a/19878
(eval (car (read-from-string (shell-command-to-string "export UMNEXTECHO=true; um next")))) (eval (car (read-from-string (shell-command-to-string (concat "export UMNEXTECHO=true; um next" descriptor)))))
;; HACK: so that the um-journal-header doesn't ;; HACK: so that the um-journal-header doesn't
;; leave the file modified. ;; leave the file modified.
(unless header (unless header