Fix date pattern in update.sh
Fix data after HEAD^1 bug