Function: magit-reset-quickly

magit-reset-quickly is an autoloaded, interactive and byte-compiled function defined in magit-reset.el.

Signature

(magit-reset-quickly COMMIT &optional HARD)

Documentation

Reset the HEAD and index to COMMIT, and possibly the working tree.

With a prefix argument reset the working tree otherwise don't.

(git reset --mixed|--hard COMMIT)

Key Bindings

Source Code

;; Defined in ~/.emacs.d/elpa/magit-20260411.1452/magit-reset.el
;;;###autoload
(defun magit-reset-quickly (commit &optional hard)
  "Reset the `HEAD' and index to COMMIT, and possibly the working tree.
With a prefix argument reset the working tree otherwise don't.
\n(git reset --mixed|--hard COMMIT)"
  (interactive (list (magit-reset-read-branch-or-commit
                      (if current-prefix-arg
                          (concat (magit--propertize-face "Hard" 'bold)
                                  " reset %s to")
                        "Reset %s to"))
                     current-prefix-arg))
  (magit-reset-internal (if hard "--hard" "--mixed") commit))