source: tools/PrettyGitLogs.sh @ 42ee8f2

aaron-thesisarm-ehcleanup-dtorsdeferred_resndemanglerjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprno_listpersistent-indexer
Last change on this file since 42ee8f2 was 42ee8f2, checked in by Thierry Delisle <tdelisle@…>, 3 years ago

PrettyGitLogs? now takes the target directory as argument

  • Property mode set to 100755
File size: 577 bytes
RevLine 
[36fb4ce8]1#!/bin/bash
2
[42ee8f2]3set -e
[36fb4ce8]4
[42ee8f2]5GIT_UPDATE="$1/GIT_UPDATE"
6GIT_LOG="$1/GIT_LOG"
7GIT_DIFF="$1/GIT_DIFF"
8
9rm -f ${GIT_UPDATE}  ${GIT_LOG}  ${GIT_DIFF}
10
11GitOldRef=$2
12GitNewRef=$3
[36fb4ce8]13
[42ee8f2]14
15revisions=$(git rev-list ${GitOldRef}..${GitNewRef})
[36fb4ce8]16
17for rev in ${revisions}; do
18    type=$(git cat-file -t ${rev})
[42ee8f2]19    echo "       via  ${rev} (${type})" >>  ${GIT_UPDATE}
[36fb4ce8]20done
21rev=${GitOldRef}
22type=$(git cat-file -t ${rev})
[42ee8f2]23echo "      from  ${rev} (${type})" >>  ${GIT_UPDATE}
[36fb4ce8]24
[42ee8f2]25git rev-list --format=short ${GitOldRef}...${GitNewRef} >  ${GIT_LOG}
[36fb4ce8]26
[42ee8f2]27git diff --stat ${GitNewRef} ${GitOldRef} >  ${GIT_DIFF}
Note: See TracBrowser for help on using the repository browser.