Skip to content

Instantly share code, notes, and snippets.

@carolyncole
Last active September 22, 2017 14:43
Show Gist options
  • Save carolyncole/4e4103f186f9908141a913c7c530d772 to your computer and use it in GitHub Desktop.
Save carolyncole/4e4103f186f9908141a913c7c530d772 to your computer and use it in GitHub Desktop.
Steps for release information
Gather the release tags
```
git tag -l v* > releases.txt
```
Edit and reorder so the tags are in numberic order (v.1.1 moves after v1.0.)
Gather the differences between versions
```
FILE=releases.txt
RELEASE1=''
RELEASE2=''
FILE=releases.txt
RELEASE1=''
RELEASE2=''
while IFS= read -r p; do
RELEASE2="$RELEASE1"
RELEASE1="$p"
fname=$(printf "log_%s" "$RELEASE1")
printf "git log --oneline %s..%s >%s 2>&1\n" "$RELEASE2" "$RELEASE1" "$fname"
cmd=$(printf "git log --oneline %s..%s" "$RELEASE2" "$RELEASE1")
$cmd > "$fname" 2>&1
done < "$FILE"
```
Count the lines in the log files
```
find . | xargs wc -l |tr -s ' '| cut -d ' ' -f 2
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment