branch: elpa/git-commit commit 6fc4bacdeea07485ba279c57da5d64eb784b879e Author: Jonas Bernoulli <jo...@bernoul.li> Commit: Jonas Bernoulli <jo...@bernoul.li>
magit-ediff-resolve-{all,rest}: Use file at point --- docs/magit.org | 10 ++++++---- docs/magit.texi | 10 ++++++---- lisp/magit-base.el | 2 ++ lisp/magit-ediff.el | 12 ++++++++++-- 4 files changed, 24 insertions(+), 10 deletions(-) diff --git a/docs/magit.org b/docs/magit.org index d649f7ffe8..715703839d 100644 --- a/docs/magit.org +++ b/docs/magit.org @@ -3498,8 +3498,9 @@ information on how to use Ediff itself, see info:ediff. - Key: E m (magit-ediff-resolve-rest) :: - This command allows you to resolve outstanding conflicts in a file - using Ediff, defaulting to the file at point. + This command allows you to resolve outstanding conflicts in the file + at point using Ediff. If there is no file at point or if it doesn't + have any unmerged changes, then this command prompts for a file. Provided that the value of ~merge.conflictstyle~ is ~diff3~, you can view the file's merge-base revision using ~/~ in the Ediff control @@ -3512,8 +3513,9 @@ information on how to use Ediff itself, see info:ediff. - Key: E m (magit-ediff-resolve-all) :: - This command allows you to resolve all conflicts in FILE using - Ediff, defaulting to the file at point. + This command allows you to resolve all conflicts in the file at + point using Ediff. If there is no file at point or if it doesn't + have any unmerged changes, then this command prompts for a file. Provided that the value of ~merge.conflictstyle~ is ~diff3~, you can view the file's merge-base revision using ~/~ in the Ediff control diff --git a/docs/magit.texi b/docs/magit.texi index ea7d1873a2..6823540237 100644 --- a/docs/magit.texi +++ b/docs/magit.texi @@ -4368,8 +4368,9 @@ common ancestor of both revisions (i.e., use a "@dots{}" range). @item @kbd{E m} (@code{magit-ediff-resolve-rest}) @kindex E m @findex magit-ediff-resolve-rest -This command allows you to resolve outstanding conflicts in a file -using Ediff, defaulting to the file at point. +This command allows you to resolve outstanding conflicts in the file +at point using Ediff. If there is no file at point or if it doesn't +have any unmerged changes, then this command prompts for a file. Provided that the value of @code{merge.conflictstyle} is @code{diff3}, you can view the file's merge-base revision using @code{/} in the Ediff control @@ -4383,8 +4384,9 @@ to not contain the actual versions from the respective blobs. @item @kbd{E m} (@code{magit-ediff-resolve-all}) @kindex E m @findex magit-ediff-resolve-all -This command allows you to resolve all conflicts in FILE using -Ediff, defaulting to the file at point. +This command allows you to resolve all conflicts in the file at +point using Ediff. If there is no file at point or if it doesn't +have any unmerged changes, then this command prompts for a file. Provided that the value of @code{merge.conflictstyle} is @code{diff3}, you can view the file's merge-base revision using @code{/} in the Ediff control diff --git a/lisp/magit-base.el b/lisp/magit-base.el index 536b3a6566..4dbfbfefc6 100644 --- a/lisp/magit-base.el +++ b/lisp/magit-base.el @@ -83,6 +83,8 @@ alphabetical order, depending on your version of Ivy." (defcustom magit-dwim-selection '((magit-stash-apply nil t) + (magit-ediff-resolve-all nil t) + (magit-ediff-resolve-rest nil t) (magit-stash-branch nil t) (magit-stash-branch-here nil t) (magit-stash-format-patch nil t) diff --git a/lisp/magit-ediff.el b/lisp/magit-ediff.el index 54f6d2ffdf..7672327603 100644 --- a/lisp/magit-ediff.el +++ b/lisp/magit-ediff.el @@ -201,7 +201,11 @@ is put in FILE." ;;;###autoload (defun magit-ediff-resolve-all (file) - "Resolve all conflicts in FILE using Ediff. + "Resolve all conflicts in the FILE at point using Ediff. + +If there is no file at point or if it doesn't have any unmerged +changes, then prompt for a file. + See info node `(magit) Ediffing' for more information about this and alternative commands." (interactive (list (magit-read-unmerged-file))) @@ -268,7 +272,11 @@ and alternative commands." ;;;###autoload (defun magit-ediff-resolve-rest (file) - "Resolve outstanding conflicts in FILE using Ediff. + "Resolve outstanding conflicts in the FILE at point using Ediff. + +If there is no file at point or if it doesn't have any unmerged +changes, then prompt for a file. + See info node `(magit) Ediffing' for more information about this and alternative commands." (interactive (list (magit-read-unmerged-file)))