{"thread":{"id":"17442","subject":"Force commit date","startedAt":"2009-01-29T18:30:17Z","lastAt":"2009-01-29T20:06:28Z","messageCount":9,"participants":["Zabre","Sverre Rabbelier","Markus Heidelberg","Daniel Barkalow"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"102481","messageId":"1233253817209-2240539.post@n2.nabble.com","threadId":"17442","inReplyTo":null,"subject":"Force commit date","fromName":"Zabre","fromEmail":"427@free.fr","sentAt":"2009-01-29T18:30:17Z","receivedAt":"2009-01-29T18:30:17Z","isPatch":false,"sender":{"key":"427@free.fr","avatar":null},"body":"\nHi all,\n\nSome time ago, I used to make 7zip backups of my project directory to keep\nan history of my changes. (I've kept all of them in separated 7z files) I\nwas then living in darkness. (Even though I tried svn but was somehow not\nhappy with it) Now I've found the light, and git is the best tool around\n(along with Hg I guess).\n\nI am learning git at the moment and I would like to restore all my 7zipped\nbackups one after the other, use meld to apply each change in the code +\ndirectory structure and then git to commit each of them, chronologically, to\nfinally obtain a complete git history of my changes (I even have \"commit\ncommentaries\" in a special text file, yes I tried to do things properly with\nbasic tools.)\n\nThis should be feasible, but what would be very cool in this very special\ncase is if I could force the commit date to reflect the real date each\n\"commit\" (read : \"zip\") was done with my old method in last year, and not\nthe date of my convertion to git.\n\nIf it is not, that's not a big deal, but I'd really like to know how to do\nthis, and have my different projects on a git history. (I even have one or\ntwo \"secondary branches\")\n\nThere might be an option I am not aware of.\n(I have seen on this forum / mailing list some people playing with dates but\nit was the case of mailboxes and \"git am\")\nhttp://n2.nabble.com/how-to-force-a-commit-date-matching-info-from-a-mbox---td2200613.html\nRemember I'm a beginner trying to learn git, so please bear with me.\n\nThank you!\n-- \nView this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240539.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"102482","messageId":"bd6139dc0901291037h46a75446occ3004d2ff58d889@mail.gmail.com","threadId":"17442","inReplyTo":"1233253817209-2240539.post@n2.nabble.com","subject":"Re: Force commit date","fromName":"Sverre Rabbelier","fromEmail":"srabbelier@gmail.com","sentAt":"2009-01-29T18:37:25Z","receivedAt":"2009-01-29T18:37:25Z","isPatch":false,"sender":{"key":"srabbelier@gmail.com","avatar":"https://avatars.githubusercontent.com/u/3098?v=4"},"body":"On Thu, Jan 29, 2009 at 19:30, Zabre <427@free.fr> wrote:\n> There might be an option I am not aware of.\n\nIndeed, try 'import-tars.perl' in the /contrib directory of git.git :).\n\n-- \nCheers,\n\nSverre Rabbelier\n"},{"id":"102483","messageId":"1233254709681-2240602.post@n2.nabble.com","threadId":"17442","inReplyTo":"1233253817209-2240539.post@n2.nabble.com","subject":"Re: Force commit date","fromName":"Zabre","fromEmail":"427@free.fr","sentAt":"2009-01-29T18:45:09Z","receivedAt":"2009-01-29T18:45:09Z","isPatch":false,"sender":{"key":"427@free.fr","avatar":null},"body":"\nI'm wondering : maybe the trick is outside git? Maybe is it possible to\nspecify a \"forced date\" at which an action (a \"git commit\" in this case) is\ndone.\nSome command that would wrap around the git commit command and tell the\nsystem \"apply this, but do it as if now was 2008-08-23 06:15:34\".\nWhat do you think?\nThis would be very interesting to know.\n(btw I'm running Linux obviously)\n-- \nView this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240602.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"102486","messageId":"1233254845678-2240620.post@n2.nabble.com","threadId":"17442","inReplyTo":"bd6139dc0901291037h46a75446occ3004d2ff58d889@mail.gmail.com","subject":"Re: Force commit date","fromName":"Zabre","fromEmail":"427@free.fr","sentAt":"2009-01-29T18:47:25Z","receivedAt":"2009-01-29T18:47:25Z","isPatch":false,"sender":{"key":"427@free.fr","avatar":null},"body":"\n\nSverre Rabbelier-2 wrote:\n> \n> Indeed, try 'import-tars.perl' in the /contrib directory of git.git :).\n> \n\nThank you Sverre, I'll have a look at this!\n(sorry for my \"wondering\" post, I had not seen yours)\n-- \nView this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240620.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"102488","messageId":"200901291955.10769.markus.heidelberg@web.de","threadId":"17442","inReplyTo":"1233254709681-2240602.post@n2.nabble.com","subject":"Re: Force commit date","fromName":"Markus Heidelberg","fromEmail":"markus.heidelberg@web.de","sentAt":"2009-01-29T18:55:10Z","receivedAt":"2009-01-29T18:55:10Z","isPatch":false,"sender":{"key":"markus.heidelberg@web.de","avatar":"https://avatars.githubusercontent.com/u/6334512?v=4"},"body":"Zabre, 29.01.2009:\n> \n> I'm wondering : maybe the trick is outside git? Maybe is it possible to\n> specify a \"forced date\" at which an action (a \"git commit\" in this case) is\n> done.\n> Some command that would wrap around the git commit command and tell the\n> system \"apply this, but do it as if now was 2008-08-23 06:15:34\".\n\nman git-commit-tree\n-> GIT_COMMITTER_DATE\n\nThough only in the git-commit-tree docs, it also works with git-commit.\nMaybe it should be added there, too.\n\nMarkus\n"},{"id":"102490","messageId":"1233255759118-2240702.post@n2.nabble.com","threadId":"17442","inReplyTo":"200901291955.10769.markus.heidelberg@web.de","subject":"Re: Force commit date","fromName":"Zabre","fromEmail":"427@free.fr","sentAt":"2009-01-29T19:02:39Z","receivedAt":"2009-01-29T19:02:39Z","isPatch":false,"sender":{"key":"427@free.fr","avatar":null},"body":"\n\nMarkus Heidelberg wrote:\n> \n> man git-commit-tree\n> -> GIT_COMMITTER_DATE\n> \n> Though only in the git-commit-tree docs, it also works with git-commit.\n> Maybe it should be added there, too.\n> \n\nThank you Markus, I'll have a look at this too !\n-- \nView this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240702.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"102491","messageId":"alpine.LNX.1.00.0901291406000.19665@iabervon.org","threadId":"17442","inReplyTo":"1233255759118-2240702.post@n2.nabble.com","subject":"Re: Force commit date","fromName":"Daniel Barkalow","fromEmail":"barkalow@iabervon.org","sentAt":"2009-01-29T19:10:20Z","receivedAt":"2009-01-29T19:10:20Z","isPatch":false,"sender":{"key":"barkalow@iabervon.org","avatar":"https://avatars.githubusercontent.com/u/55364219?v=4"},"body":"On Thu, 29 Jan 2009, Zabre wrote:\n\n> Markus Heidelberg wrote:\n> > \n> > man git-commit-tree\n> > -> GIT_COMMITTER_DATE\n> > \n> > Though only in the git-commit-tree docs, it also works with git-commit.\n> > Maybe it should be added there, too.\n> > \n> \n> Thank you Markus, I'll have a look at this too !\n\nYou may want to consider whether those dates make most sense as the date \nof the commit, or the date the changes were done; git tracks both of \nthese separately, in part because it's easy to have some work done at one \ntime, and only make the commit that becomes part of the official project \nhistory much later (and these may be done by different people).\n\nThe date for the changes being done is set with GIT_AUTHOR_DATE\n\n\t-Daniel\n*This .sig left intentionally blank*\n"},{"id":"102494","messageId":"1233258537869-2240926.post@n2.nabble.com","threadId":"17442","inReplyTo":"alpine.LNX.1.00.0901291406000.19665@iabervon.org","subject":"Re: Force commit date","fromName":"Zabre","fromEmail":"427@free.fr","sentAt":"2009-01-29T19:48:57Z","receivedAt":"2009-01-29T19:48:57Z","isPatch":false,"sender":{"key":"427@free.fr","avatar":null},"body":"\n\nDaniel Barkalow wrote:\n> \n> You may want to consider whether those dates make most sense as the date \n> of the commit, or the date the changes were done; git tracks both of \n> these separately, in part because it's easy to have some work done at one \n> time, and only make the commit that becomes part of the official project \n> history much later (and these may be done by different people).\n> \n> The date for the changes being done is set with GIT_AUTHOR_DATE\n> \n\nThank you Daniel, this is very interesting, having a GIT_COMMITTER_DATE and\na GIT_AUTHOR_DATE enables me to have both dates, and no need to trick the\nsystem then.\n-- \nView this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240926.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"102498","messageId":"1233259588952-2241010.post@n2.nabble.com","threadId":"17442","inReplyTo":"1233258537869-2240926.post@n2.nabble.com","subject":"Re: Force commit date","fromName":"Zabre","fromEmail":"427@free.fr","sentAt":"2009-01-29T20:06:28Z","receivedAt":"2009-01-29T20:06:28Z","isPatch":false,"sender":{"key":"427@free.fr","avatar":null},"body":"\nFor the record, this thread is similar to : \nhttp://n2.nabble.com/Committing-with-past-date--td795326.html\n-- \nView this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2241010.html\nSent from the git mailing list archive at Nabble.com.\n"}]}