@@ -45,7 +45,7 @@ jobs:
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "changelog=$(cat $CHANGELOG_FILE)" >> $GITHUB_OUTPUT
|
||||
echo "changelog_file=$CHANGELOG_FILE" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Build Artifacts
|
||||
if: steps.tag.outputs.version
|
||||
@@ -59,18 +59,17 @@ jobs:
|
||||
id: create_release
|
||||
run: |
|
||||
VERSION="${{ steps.tag.outputs.version }}"
|
||||
CHANGELOG="${{ steps.changelog.outputs.changelog }}"
|
||||
RESPONSE=$(curl -s -X POST \
|
||||
CHANGELOG_FILE="${{ steps.changelog.outputs.changelog_file }}"
|
||||
RESPONSE=$(jq -n \
|
||||
--arg tag "v$VERSION" \
|
||||
--arg name "wapp-v$VERSION" \
|
||||
--rawfile body "$CHANGELOG_FILE" \
|
||||
'{tag_name: $tag, name: $name, body: $body, draft: false, prerelease: false}' \
|
||||
| curl -s -X POST \
|
||||
-H "Authorization: token ${{ secrets.GITEA_TOKEN }}" \
|
||||
-H "Content-Type: application/json" \
|
||||
"https://git.thewizardapprentice.com/api/v1/repos/${{ gitea.repository }}/releases" \
|
||||
-d '{
|
||||
"tag_name": "v'"$VERSION"'",
|
||||
"name": "wapp-v'"$VERSION"'",
|
||||
"body": "'"$CHANGELOG"'",
|
||||
"draft": false,
|
||||
"prerelease": false
|
||||
}')
|
||||
--data-binary @- \
|
||||
"https://git.thewizardapprentice.com/api/v1/repos/${{ gitea.repository }}/releases")
|
||||
|
||||
echo "$RESPONSE"
|
||||
RELEASE_ID=$(echo $RESPONSE | jq -r '.id')
|
||||
|
||||
Reference in New Issue
Block a user