`(let ((output-buf (get-buffer-create ,(or name "*StGit output*")))
(stgit-dir default-directory)
(inhibit-read-only t))
`(let ((output-buf (get-buffer-create ,(or name "*StGit output*")))
(stgit-dir default-directory)
(inhibit-read-only t))
(interactive (list (read-string "Patch name: " (stgit-patch-at-point))))
(let ((old-name (stgit-patch-at-point)))
(unless old-name
(interactive (list (read-string "Patch name: " (stgit-patch-at-point))))
(let ((old-name (stgit-patch-at-point)))
(unless old-name
(interactive (list (stgit-patches-marked-or-at-point)))
(if (zerop (length patch-names))
(error "No patches to delete")
(interactive (list (stgit-patches-marked-or-at-point)))
(if (zerop (length patch-names))
(error "No patches to delete")