git-reset-scripton commit ls-remote: drop storing operation and add documentation. (972b6fe)
   1#!/bin/sh
   2. git-sh-setup-script || die "Not a git archive"
   3rev=$(git-rev-parse --revs-only --verify --default HEAD "$@") || exit
   4rev=$(git-rev-parse --revs-only --verify $rev^0) || exit
   5git-read-tree --reset "$rev" && {
   6        if orig=$(git-rev-parse --verify HEAD 2>/dev/null)
   7        then
   8                echo "$orig" >"$GIT_DIR/ORIG_HEAD"
   9        fi
  10        echo "$rev" > "$GIT_DIR/HEAD"
  11}
  12git-update-cache --refresh
  13rm -f "$GIT_DIR/MERGE_HEAD"