"be diff" now compares agains the last commit (for versioning VCSs).
authorW. Trevor King <wking@drexel.edu>
Thu, 23 Jul 2009 18:24:36 +0000 (14:24 -0400)
committerW. Trevor King <wking@drexel.edu>
Thu, 23 Jul 2009 18:24:36 +0000 (14:24 -0400)
This is the default behaviour of most of the VCSs own diff commands.

becommands/diff.py

index 4b319ca61cb5294cfc6188484acd97f64b07a8ec..07b3b1c7961b5d005aa558cbe219a5e16fb7c2b1 100644 (file)
@@ -52,6 +52,8 @@ def execute(args, manipulate_encodings=True):
     if bd.rcs.versioned == False:
         print "This directory is not revision-controlled."
     else:
+        if revision == None: # get the most recent revision
+            revision = bd.rcs.revision_id(-1)
         old_bd = bd.duplicate_bugdir(revision)
         r,m,a = diff.bug_diffs(old_bd, bd)