changeset 22371:81ad62defef5

revert: add documentation in the dispatch table More sets are coming so documenting the existing ones will help.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Sat, 30 Aug 2014 01:48:58 +0200
parents 45e02cfad4bd
children 8da5864dcfda
files mercurial/cmdutil.py
diffstat 1 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/cmdutil.py	Sat Aug 30 02:47:59 2014 +0200
+++ b/mercurial/cmdutil.py	Sat Aug 30 01:48:58 2014 +0200
@@ -2518,12 +2518,22 @@
             #   file state
             #   action
             #   make backup
+
+            ## Sets that results that will change file on disk
+            # Modified compared to target, no local change
             (modified,   actions['revert'],   discard),
+            # Modified compared to target, local change
             (dsmodified, actions['revert'],   backup),
+            # Added since target
             (dsadded,    actions['remove'],   backup),
+            # Removed since  target, before working copy parent
             (removed,    actions['add'],      backup),
+            # Removed since targe, marked as such in working copy parent
             (dsremoved,  actions['undelete'], backup),
+            ## the following sets does not result in any file changes
+            # File with no modification
             (clean,      actions['noop'],     discard),
+            # Existing file, not tracked anywhere
             (unknown,    actions['unknown'],  discard),
             )