#!/bin/bash if [ ! -d .git ]; then echo "missing .git dir!" exit 1 fi echo "Last commit: $(git log | grep 'Date' | cut -d ' ' -f 4- | head -1)" read -p "Date: " date export GIT_AUTHOR_DATE="${date}" export GIT_COMMITTER_DATE="${date}" git "$@"