Function: log-view-revert-or-delete-revisions
log-view-revert-or-delete-revisions is an interactive and
byte-compiled function defined in log-view.el.gz.
Signature
(log-view-revert-or-delete-revisions DIRECTORY &optional INTERACTIVE DELETE)
Documentation
Undo the effects of the revision at point.
When revisions are marked, undo the effects of each of them. When called interactively, prompts for the target working tree in which to revert; the current working tree is the default choice. When called from Lisp, DIRECTORY is the root of the target working tree.
When called interactively (or with optional argument INTERACTIVE non-nil), then if the underlying VCS is distributed, offer to entirely delete revisions that have not been pushed. This is instead of creating new commits undoing their effects.
With a prefix argument (or with optional argument DELETE non-nil),
always delete revisions and never create new commits.
In this case INTERACTIVE is ignored.
This works only for unpublished commits, unless you have customized
vc-allow-rewriting-published-history to a non-nil value.
When reverting a single revision, prompts for editing the log message for the new commit. When reverting multiple revisions, never prompts to edit log messages.
See also vc-revert-or-delete-revision.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/vc/log-view.el.gz
(defun log-view-revert-or-delete-revisions
(directory &optional interactive delete)
"Undo the effects of the revision at point.
When revisions are marked, undo the effects of each of them.
When called interactively, prompts for the target working tree in which
to revert; the current working tree is the default choice.
When called from Lisp, DIRECTORY is the root of the target working tree.
When called interactively (or with optional argument INTERACTIVE
non-nil), then if the underlying VCS is distributed, offer to entirely
delete revisions that have not been pushed.
This is instead of creating new commits undoing their effects.
With a prefix argument (or with optional argument DELETE non-nil),
always delete revisions and never create new commits.
In this case INTERACTIVE is ignored.
This works only for unpublished commits, unless you have customized
`vc-allow-rewriting-published-history' to a non-nil value.
When reverting a single revision, prompts for editing the log message
for the new commit.
When reverting multiple revisions, never prompts to edit log messages.
See also `vc-revert-or-delete-revision'."
(interactive (list (vc--prompt-other-working-tree
(vc-responsible-backend default-directory)
(if current-prefix-arg "Delete in working tree"
"Revert in working tree")
'allow-empty)
t current-prefix-arg))
(log-view--pick-or-revert directory nil t interactive delete))