git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / Atom feed
* How do I change the AuthorDate and CommitDate of all my commits?
@ 2020-01-16 11:30 gritzmann
  2020-02-14  6:32 ` Jeff King
  0 siblings, 1 reply; 2+ messages in thread
From: gritzmann @ 2020-01-16 11:30 UTC (permalink / raw)
  To: git

Hi,

I*m looking to completely anonymize the timestamps of my files and repos For the files themselves I changed their access, modify, change and birth times like this: `touch -acm -d "1980-01-01 00:00:00"`.

But how do I do the same for the AuthorDate and CommitDate of all my commits?

Thanks!

Sent with ProtonMail Secure Email.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: How do I change the AuthorDate and CommitDate of all my commits?
  2020-01-16 11:30 How do I change the AuthorDate and CommitDate of all my commits? gritzmann
@ 2020-02-14  6:32 ` Jeff King
  0 siblings, 0 replies; 2+ messages in thread
From: Jeff King @ 2020-02-14  6:32 UTC (permalink / raw)
  To: gritzmann; +Cc: git

On Thu, Jan 16, 2020 at 11:30:10AM +0000, gritzmann wrote:

> I*m looking to completely anonymize the timestamps of my files and
> repos For the files themselves I changed their access, modify, change
> and birth times like this: `touch -acm -d "1980-01-01 00:00:00"`.
> 
> But how do I do the same for the AuthorDate and CommitDate of all my
> commits?

If you're just creating the commits now, you can set $GIT_AUTHOR_DATE
and $GIT_COMMITTER_DATE in the environment. Like:

  export GIT_AUTHOR_DATE='1980-01-01 00:00:00 +0000'
  export GIT_COMMITTER_DATE="$GIT_AUTHOR_DATE"

If you have existing commits, you'll have to look into rewriting them
with git-filter-branch, or piping git-fast-export to git-fast-import and
modifying the stream in between.

-Peff

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-16 11:30 How do I change the AuthorDate and CommitDate of all my commits? gritzmann
2020-02-14  6:32 ` Jeff King

git@vger.kernel.org list mirror (unofficial, one of many)

Archives are clonable:
	git clone --mirror https://public-inbox.org/git
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

Example config snippet for mirrors

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.version-control.git
	nntp://ou63pmih66umazou.onion/inbox.comp.version-control.git
	nntp://czquwvybam4bgbro.onion/inbox.comp.version-control.git
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.version-control.git
	nntp://news.gmane.io/gmane.comp.version-control.git

 note: .onion URLs require Tor: https://www.torproject.org/

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git