]> thyrsus.com Git - rcs-fast-import.git/commitdiff
Disable journaling until we need it.
authorEric S. Raymond <esr@thyrsus.com>
Fri, 12 Nov 2010 02:21:19 +0000 (21:21 -0500)
committerEric S. Raymond <esr@thyrsus.com>
Fri, 12 Nov 2010 02:21:19 +0000 (21:21 -0500)
rcs-fast-import

index 4a31bbefdde4d5e6ed035562c101a7e4ecef8fe2..4f7668cfeb4f5efc06dd0b1b08abaf77c255b1ce 100755 (executable)
@@ -548,13 +548,13 @@ class RCS:
     "Class encapsulating RCS version-control operations."
     historyfile = ".HISTORY"
     def __init__(self):
-        # Rev-to-branch map will go here
-        if not os.path.exists("RCS"):
-            try:
-                os.makedirs("RCS")
-            except OSError:
-                raise FatalException("can't create RCS directory.")
-        file(RCS.historyfile, "w").close()
+        if verbose:
+            if not os.path.exists("RCS"):
+                try:
+                    os.makedirs("RCS")
+                except OSError:
+                    raise FatalException("can't create RCS directory.")
+            file(RCS.historyfile, "w").close()
     @staticmethod
     def master(filename):
         "Return the master file corresponding to a specified filename."
@@ -592,7 +592,8 @@ class RCS:
                 fp.write(path)
             fp.write("\n")
     def precommit(self, event):
-        RCS.record("commit")
+        if verbose:
+            RCS.record("commit")
     def modify(self, event, path, mode, copyfile, roundtrip):
         "Perform RCS file checkins and modifications,"
         if mode == "160000":
@@ -672,7 +673,8 @@ class RCS:
             do_or_die("rcs -u %s" % (" ".join(RCS.rcsfiles()),))
             if switch == '-u':
                 do_or_die("co -u %s" % (" ".join(RCS.rcsfiles()),))
-        os.rename(RCS.historyfile, os.path.join("RCS", RCS.historyfile))
+        if verbose:
+            os.rename(RCS.historyfile, os.path.join("RCS", RCS.historyfile))
 
 if __name__ == '__main__':
     (options, arguments) = getopt.getopt(sys.argv[1:], "lnpuvV?")