added multi commit changelogs!

This commit is contained in:
Bella 2020-04-27 20:11:16 -04:00
parent 868019329a
commit ad62fedec8
No known key found for this signature in database
GPG Key ID: DBD4A6030080C8B3
1 changed files with 3 additions and 1 deletions

View File

@ -13,10 +13,12 @@ JAR_DIR="$(ls "$BUILD_DIR" | grep "release")"
# Upload the release file
#curl -F content=@"$BUILD_DIR/$JAR_DIR" "$WEBHOOK"
CHANGELOG_FULL="$(git log --format=%s $COMMIT_TRIM...$COMMIT_LAST | sed ':a;N;$!ba;s/\n/\\n/g')"
# Upload the release
cd ~/
source ~/.profile
./github-release-linux-amd64 $CUR_VER-$COMMIT_TRIM $BUILD_DIR/$JAR_DIR --github-access-token $GITHUB_RELEASE_ACCESS_TOKEN --github-repository $GITHUB_RELEASE_REPOSITORY
# Send message with commit information
curl -H "Content-Type: application/json" -X POST -d '{"embeds": [{"title": "Download '$CUR_VER\-$COMMIT_TRIM'","color": 10195199,"description": "**Download:** ['${CUR_VER}\-${COMMIT_TRIM}'](https://github.com/kami-blue/nightly-releases/releases/download/'$CUR_VER\-$COMMIT_TRIM'/'${JAR_DIR}')\n**Changelog:** '"$COMMIT_MSG"'\nCommit: ['${COMMIT_TRIM}'](https://github.com/kami-blue/client/commits/'${COMMIT_TRIM}') Direct: ['${COMMIT_TRIM}'](https://github.com/kami-blue/client/commit/'${COMMIT_FULL}') "}]}' "$WEBHOOK"
curl -H "Content-Type: application/json" -X POST -d '{"embeds": [{"title": "Download '$CUR_VER\-$COMMIT_TRIM'","color": 10195199,"description": "**Download:** ['${CUR_VER}\-${COMMIT_TRIM}'](https://github.com/kami-blue/nightly-releases/releases/download/'$CUR_VER\-$COMMIT_TRIM'/'${JAR_DIR}')\n**Changelog:** \n'"$CHANGELOG_FULL"'\nCommit: ['${COMMIT_TRIM}'](https://github.com/kami-blue/client/commit/'${COMMIT_FULL}') "}]}' "$WEBHOOK"