Using git for past

If you have some changes that you want to be shown as it were committed in past, then you may use this command:

GIT_AUTHOR_DATE='Mon Jan 26 16:32:33 2015 +0530' 
GIT_COMMITTER_DATE='Mon Jan 26 16:32:33 2015 +0530'
git commit -m 'commit message here'

It will commit the staged files committed as per the date given. Take care of the +0530, it should be your timezone.

If you want to change a commit from the log list then get the workaround here: http://stackoverflow.com/a/3896112/3784226

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s