Fix 'Cannot get this file-path' when bumping in babel edit buffers

Break glass in case of literate configs.
This commit is contained in:
Henrik Lissner 2020-05-25 01:19:03 -04:00
parent 6a8e990459
commit 09c6e99e23
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -37,8 +37,11 @@
(when (eq (car-safe (sexp-at-point)) 'package!) (when (eq (car-safe (sexp-at-point)) 'package!)
(cl-destructuring-bind (beg . end) (cl-destructuring-bind (beg . end)
(bounds-of-thing-at-point 'sexp) (bounds-of-thing-at-point 'sexp)
(let ((package (let (doom-packages) (let* ((doom-packages nil)
(eval (sexp-at-point) t)))) (buffer-file-name
(or buffer-file-name
(bound-and-true-p org-src-source-file-name)))
(package (eval (sexp-at-point) t)))
(list :beg beg (list :beg beg
:end end :end end
:package (car package) :package (car package)