fix(lib): doom/bumpify-diff: skip non-package! forms
Would formerly error out if it tries to read invalid forms in misc files included in bump commits.
This commit is contained in:
parent
d55b078fa1
commit
88c59129ec
1 changed files with 8 additions and 7 deletions
|
@ -239,13 +239,14 @@ Must be run from a magit diff buffer."
|
||||||
(unless (= (length before) (length after))
|
(unless (= (length before) (length after))
|
||||||
(user-error "Uneven number of packages being bumped"))
|
(user-error "Uneven number of packages being bumped"))
|
||||||
(dolist (p1 before)
|
(dolist (p1 before)
|
||||||
|
(when (and (listp p1) (eq (car p1) 'package!))
|
||||||
(cl-destructuring-bind (package &key plist _beg _end &allow-other-keys) p1
|
(cl-destructuring-bind (package &key plist _beg _end &allow-other-keys) p1
|
||||||
(let ((p2 (cdr (assq package after))))
|
(let ((p2 (cdr (assq package after))))
|
||||||
(if (null p2)
|
(if (null p2)
|
||||||
(push package errors)
|
(push package errors)
|
||||||
(let ((bstr1 (doom--package-to-bump-string package plist))
|
(let ((bstr1 (doom--package-to-bump-string package plist))
|
||||||
(bstr2 (doom--package-to-bump-string package (plist-get p2 :plist))))
|
(bstr2 (doom--package-to-bump-string package (plist-get p2 :plist))))
|
||||||
(cl-pushnew (format "%s -> %s" bstr1 bstr2) lines :test #'equal))))))
|
(cl-pushnew (format "%s -> %s" bstr1 bstr2) lines :test #'equal)))))))
|
||||||
(if (null lines)
|
(if (null lines)
|
||||||
(user-error "No bumps to bumpify")
|
(user-error "No bumps to bumpify")
|
||||||
(prog1 (funcall (if interactive #'kill-new #'identity)
|
(prog1 (funcall (if interactive #'kill-new #'identity)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue