]> andersk Git - svn-all-fast-export.git/commitdiff
Output dates in the local timezone.
authorAnders Kaseorg <andersk@mit.edu>
Sat, 3 Jan 2009 21:10:34 +0000 (16:10 -0500)
committerAnders Kaseorg <andersk@mit.edu>
Tue, 6 Jul 2010 17:00:22 +0000 (13:00 -0400)
src/repository.cpp

index 182309c27bd8ca4044e9e4033d7a42f0e0be1b47..dd96060933a7714ccf95f4557f7f098cd6a0d54d 100644 (file)
@@ -20,6 +20,7 @@
 #include <QTextStream>
 #include <QDebug>
 #include <QLinkedList>
+#include <time.h>
 
 static const int maxSimultaneousProcesses = 100;
 
@@ -332,7 +333,10 @@ void Repository::Transaction::commit()
 
         QTextStream s(&repository->fastImport);
         s << "commit " << branchRef << endl;
-        s << "committer " << QString::fromUtf8(author) << ' ' << datetime << " -0000" << endl;
+        time_t t = datetime;
+        char zone[16];
+        strftime(zone, sizeof(zone), " %z", localtime(&t));
+        s << "committer " << QString::fromUtf8(author) << ' ' << datetime << zone << endl;
 
         Branch &br = repository->branches[branch];
         if (!br.created) {
This page took 0.265851 seconds and 5 git commands to generate.