2005-06-15 03:56:05 +02:00
|
|
|
#!/bin/sh
|
2005-07-08 19:57:21 +02:00
|
|
|
. git-sh-setup-script || die "Not a git archive"
|
2005-08-07 03:01:03 +02:00
|
|
|
rev=$(git-rev-parse --revs-only --verify --default HEAD "$@") || exit
|
|
|
|
rev=$(git-rev-parse --revs-only --verify $rev^0) || exit
|
2005-08-07 05:59:47 +02:00
|
|
|
git-read-tree --reset "$rev" && {
|
|
|
|
if orig=$(git-rev-parse --verify HEAD 2>/dev/null)
|
|
|
|
then
|
|
|
|
echo "$orig" >"$GIT_DIR/ORIG_HEAD"
|
|
|
|
fi
|
|
|
|
echo "$rev" > "$GIT_DIR/HEAD"
|
|
|
|
}
|
2005-06-15 03:56:05 +02:00
|
|
|
git-update-cache --refresh
|
2005-06-22 00:40:00 +02:00
|
|
|
rm -f "$GIT_DIR/MERGE_HEAD"
|