From: Edward Z. Yang Date: Sun, 10 Jan 2010 08:20:49 +0000 (-0500) Subject: Fix semantics for date falsification to use scripts. X-Git-Url: https://scripts.mit.edu/gitweb/wizard.git/commitdiff_plain/e9b8c72335cf50ce70ded9b62c7fe25fe6fb46ad Fix semantics for date falsification to use scripts. Signed-off-by: Edward Z. Yang --- diff --git a/bin/prepare-retro-upgrade b/bin/prepare-retro-upgrade index eaa9e62..131efdc 100755 --- a/bin/prepare-retro-upgrade +++ b/bin/prepare-retro-upgrade @@ -28,7 +28,7 @@ git reset --hard $APP-$PRIOR-scripts git checkout -b tpristine || git checkout tpristine git reset --hard $APP-$PRIOR -DATE=`git show HEAD --format="format:%cd" | head -n1` +DATE=`git show tmaster --format="format:%cd" | head -n1` export GIT_AUTHOR_DATE="$DATE" export GIT_COMMITTER_DATE="$DATE" diff --git a/doc/upgrade.rst b/doc/upgrade.rst index 0cb405b..be9c236 100644 --- a/doc/upgrade.rst +++ b/doc/upgrade.rst @@ -175,9 +175,10 @@ to these tags:: git checkout -b tpristine git reset --hard 1.0 -Find the committer time associated with the ``tmaster`` commit using ``git show tmaster`` -and note it somewhere (we will refer to it in the environment variable -``$DATE``.) +Find the committer date associated with the ``tmaster`` commit using ``git show tmaster`` +and note it somewhere:: + + DATE=`git show tmaster --format="format:%cd" | head -n1` Next, begin performing ordinary procedure for preparing the pristine copy. There are two caveats: you will need to use ``--force`` @@ -220,7 +221,9 @@ Note that ``$VERSION`` is specified explicitly. If there are changes, manually restore any custom changes we may have made, then amend your commit and push back:: - git commit --amend -a + # you probably lost your environment variable + DATE=`git show HEAD --format="format:%cd" | head -n1` + env GIT_AUTHOR_DATE="$DATE" GIT_COMMITTER_DATE="$DATE" git commit --amend -a git tag -d $APP-$VERSION-scripts git tag $APP-$VERSION-scripts git push --force