* Force commit date
@ 2009-01-29 18:30 Zabre
2009-01-29 18:37 ` Sverre Rabbelier
2009-01-29 18:45 ` Zabre
0 siblings, 2 replies; 9+ messages in thread
From: Zabre @ 2009-01-29 18:30 UTC (permalink / raw)
To: git
Hi all,
Some time ago, I used to make 7zip backups of my project directory to keep
an history of my changes. (I've kept all of them in separated 7z files) I
was then living in darkness. (Even though I tried svn but was somehow not
happy with it) Now I've found the light, and git is the best tool around
(along with Hg I guess).
I am learning git at the moment and I would like to restore all my 7zipped
backups one after the other, use meld to apply each change in the code +
directory structure and then git to commit each of them, chronologically, to
finally obtain a complete git history of my changes (I even have "commit
commentaries" in a special text file, yes I tried to do things properly with
basic tools.)
This should be feasible, but what would be very cool in this very special
case is if I could force the commit date to reflect the real date each
"commit" (read : "zip") was done with my old method in last year, and not
the date of my convertion to git.
If it is not, that's not a big deal, but I'd really like to know how to do
this, and have my different projects on a git history. (I even have one or
two "secondary branches")
There might be an option I am not aware of.
(I have seen on this forum / mailing list some people playing with dates but
it was the case of mailboxes and "git am")
http://n2.nabble.com/how-to-force-a-commit-date-matching-info-from-a-mbox---td2200613.html
Remember I'm a beginner trying to learn git, so please bear with me.
Thank you!
--
View this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240539.html
Sent from the git mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Force commit date
2009-01-29 18:30 Force commit date Zabre
@ 2009-01-29 18:37 ` Sverre Rabbelier
2009-01-29 18:47 ` Zabre
2009-01-29 18:45 ` Zabre
1 sibling, 1 reply; 9+ messages in thread
From: Sverre Rabbelier @ 2009-01-29 18:37 UTC (permalink / raw)
To: Zabre; +Cc: git
On Thu, Jan 29, 2009 at 19:30, Zabre <427@free.fr> wrote:
> There might be an option I am not aware of.
Indeed, try 'import-tars.perl' in the /contrib directory of git.git :).
--
Cheers,
Sverre Rabbelier
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Force commit date
2009-01-29 18:30 Force commit date Zabre
2009-01-29 18:37 ` Sverre Rabbelier
@ 2009-01-29 18:45 ` Zabre
2009-01-29 18:55 ` Markus Heidelberg
1 sibling, 1 reply; 9+ messages in thread
From: Zabre @ 2009-01-29 18:45 UTC (permalink / raw)
To: git
I'm wondering : maybe the trick is outside git? Maybe is it possible to
specify a "forced date" at which an action (a "git commit" in this case) is
done.
Some command that would wrap around the git commit command and tell the
system "apply this, but do it as if now was 2008-08-23 06:15:34".
What do you think?
This would be very interesting to know.
(btw I'm running Linux obviously)
--
View this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240602.html
Sent from the git mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Force commit date
2009-01-29 18:45 ` Zabre
@ 2009-01-29 18:55 ` Markus Heidelberg
2009-01-29 19:02 ` Zabre
0 siblings, 1 reply; 9+ messages in thread
From: Markus Heidelberg @ 2009-01-29 18:55 UTC (permalink / raw)
To: Zabre; +Cc: git
Zabre, 29.01.2009:
>
> I'm wondering : maybe the trick is outside git? Maybe is it possible to
> specify a "forced date" at which an action (a "git commit" in this case) is
> done.
> Some command that would wrap around the git commit command and tell the
> system "apply this, but do it as if now was 2008-08-23 06:15:34".
man git-commit-tree
-> GIT_COMMITTER_DATE
Though only in the git-commit-tree docs, it also works with git-commit.
Maybe it should be added there, too.
Markus
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Force commit date
2009-01-29 18:55 ` Markus Heidelberg
@ 2009-01-29 19:02 ` Zabre
2009-01-29 19:10 ` Daniel Barkalow
0 siblings, 1 reply; 9+ messages in thread
From: Zabre @ 2009-01-29 19:02 UTC (permalink / raw)
To: git
Markus Heidelberg wrote:
>
> man git-commit-tree
> -> GIT_COMMITTER_DATE
>
> Though only in the git-commit-tree docs, it also works with git-commit.
> Maybe it should be added there, too.
>
Thank you Markus, I'll have a look at this too !
--
View this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240702.html
Sent from the git mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Force commit date
2009-01-29 19:02 ` Zabre
@ 2009-01-29 19:10 ` Daniel Barkalow
2009-01-29 19:48 ` Zabre
0 siblings, 1 reply; 9+ messages in thread
From: Daniel Barkalow @ 2009-01-29 19:10 UTC (permalink / raw)
To: Zabre; +Cc: git
On Thu, 29 Jan 2009, Zabre wrote:
> Markus Heidelberg wrote:
> >
> > man git-commit-tree
> > -> GIT_COMMITTER_DATE
> >
> > Though only in the git-commit-tree docs, it also works with git-commit.
> > Maybe it should be added there, too.
> >
>
> Thank you Markus, I'll have a look at this too !
You may want to consider whether those dates make most sense as the date
of the commit, or the date the changes were done; git tracks both of
these separately, in part because it's easy to have some work done at one
time, and only make the commit that becomes part of the official project
history much later (and these may be done by different people).
The date for the changes being done is set with GIT_AUTHOR_DATE
-Daniel
*This .sig left intentionally blank*
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Force commit date
2009-01-29 19:10 ` Daniel Barkalow
@ 2009-01-29 19:48 ` Zabre
2009-01-29 20:06 ` Zabre
0 siblings, 1 reply; 9+ messages in thread
From: Zabre @ 2009-01-29 19:48 UTC (permalink / raw)
To: git
Daniel Barkalow wrote:
>
> You may want to consider whether those dates make most sense as the date
> of the commit, or the date the changes were done; git tracks both of
> these separately, in part because it's easy to have some work done at one
> time, and only make the commit that becomes part of the official project
> history much later (and these may be done by different people).
>
> The date for the changes being done is set with GIT_AUTHOR_DATE
>
Thank you Daniel, this is very interesting, having a GIT_COMMITTER_DATE and
a GIT_AUTHOR_DATE enables me to have both dates, and no need to trick the
system then.
--
View this message in context: http://n2.nabble.com/Force-commit-date-tp2240539p2240926.html
Sent from the git mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2009-01-29 20:07 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-29 18:30 Force commit date Zabre
2009-01-29 18:37 ` Sverre Rabbelier
2009-01-29 18:47 ` Zabre
2009-01-29 18:45 ` Zabre
2009-01-29 18:55 ` Markus Heidelberg
2009-01-29 19:02 ` Zabre
2009-01-29 19:10 ` Daniel Barkalow
2009-01-29 19:48 ` Zabre
2009-01-29 20:06 ` Zabre
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).