]> scripts.mit.edu Git - wizard.git/commitdiff
Fix semantics for date falsification to use scripts.
authorEdward Z. Yang <ezyang@mit.edu>
Sun, 10 Jan 2010 08:20:49 +0000 (03:20 -0500)
committerEdward Z. Yang <ezyang@mit.edu>
Sun, 10 Jan 2010 08:20:49 +0000 (03:20 -0500)
Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
bin/prepare-retro-upgrade
doc/upgrade.rst

index eaa9e621b09408341dc3b07c325c21c855d22f0c..131efdc60a209e83949524efec09c22ebd8fd5d9 100755 (executable)
@@ -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"
index 0cb405bc9d0e509746f518bf87643e1fe7b91ecf..be9c2363e425fc147c04185563240048cb124b58 100644 (file)
@@ -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