@matheusbsbs / matheus-bagliano / commits / 6581de096e
Fork 0

Write out the options tag in the log message of imports only if we actually have options

Write out the options tag in the log message of imports only if we actually have options Signed-off-by: Simon Hausmann <simon@lst.de>

Simon Hausmann committed Jun 11, 2007 at 10:01 UTC 6581de096e8323385b8ec7d467e91927a80ce3b9
1 file changed +5 -6
contrib/fast-import/git-p4
+5 -6
@@ -765,12 +765,11 @@ class P4Sync(Command):
765
766 self.gitStream.write("data <<EOT\n")
767 self.gitStream.write(details["desc"])
768 - self.gitStream.write("\n[git-p4: depot-paths = \"%s\": change = %s: "
769 - "options = %s]\n"
770 - % (','.join (branchPrefixes), details["change"],
771 - details['options']
772 - ))
773 - self.gitStream.write("EOT\n\n")
768 + self.gitStream.write("\n[git-p4: depot-paths = \"%s\": change = %s"
769 + % (','.join (branchPrefixes), details["change"]))
770 + if len(details['options']) > 0:
771 + self.gitStream.write(": options = %s" % details['options'])
772 + self.gitStream.write("]\nEOT\n\n")
773
774 if len(parent) > 0:
775 if self.verbose: