Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save christo4ferris/8f67095f20145d81aa051359be9e68d3 to your computer and use it in GitHub Desktop.
Save christo4ferris/8f67095f20145d81aa051359be9e68d3 to your computer and use it in GitHub Desktop.
new change log.sh
#!/bin/sh
echo "## $3\n$(date)\n\n" >> CHANGELOG.new
git log $1..$2 --oneline | grep -v Merge | sed -e "s/\[\(FAB-[0-9]*\)\]/\[\1\](https:\/\/jira.hyperledger.org\/browse\/\1\)/" -e "s/ \(FAB-[0-9]*\)/ \[\1\](https:\/\/jira.hyperledger.org\/browse\/\1\)/" -e "s/\([0-9|a-z]*\)/* \[\1\](https:\/\/github.com\/hyperledger\/fabric\/commit\/\1)/" >> CHANGELOG.new
echo "" >> CHANGELOG.new
cat CHANGELOG.md >> CHANGELOG.new
mv -f CHANGELOG.new CHANGELOG.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment