Function: magit--run-git-stash
magit--run-git-stash is a byte-compiled function defined in
magit-stash.el.
Signature
(magit--run-git-stash &rest ARGS)
Source Code
;; Defined in ~/.emacs.d/elpa/magit-20260411.1452/magit-stash.el
(defun magit--run-git-stash (&rest args)
(magit--with-temp-process-buffer
(let ((exit (save-excursion
(with-environment-variables (("LC_ALL" "en_US.utf8"))
(magit-process-git t "stash" args))))
(buffer (current-buffer))
(failed (looking-at "\\`error: ")))
(with-current-buffer (magit-process-buffer t)
(magit-process-finish-section
(magit-process-insert-section default-directory magit-git-executable
(magit-process-git-arguments args)
exit buffer)
exit))
(pcase (list exit failed)
(`(0 ,_) t) ; no conflict
(`(1 nil) t) ; successfully installed conflict
(_ nil))))) ; could not install conflict, or genuine error