Skip to content

Commit

Permalink
Add debugging information for DEPLOY_URL in release action.
Browse files Browse the repository at this point in the history
  • Loading branch information
zgypa committed Mar 28, 2024
1 parent d24bf80 commit 9c90b35
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,13 @@ jobs:
# Loop through and upload each asset in the dist/ directory
for filename in build/*; do
echo "Uploading ${filename}"
asset_path=${filename}
asset_name=$(basename ${filename})
FULL_UPLOAD_URL="${UPLOAD_URL}?name=${asset_name}"
echo "Uploading ${filename} to ${FULL_UPLOAD_URL}"
# Upload asset
HTTP_RESPONSE=$(curl -s -o response.txt -w "%{http_code}" -X POST -H "Authorization: token $GITHUB_TOKEN" -H "Content-Type: application/octet-stream" --data-binary @"${asset_path}" "${UPLOAD_URL}?name=${asset_name}")
HTTP_RESPONSE=$(curl -s -o response.txt -w "%{http_code}" -X POST -H "Authorization: token $GITHUB_TOKEN" -H "Content-Type: application/octet-stream" --data-binary @"${asset_path}" "${FULL_UPLOAD_URL}")
if [ "$HTTP_RESPONSE" -eq "201" ]; then
echo "Successfully uploaded ${asset_name}"
Expand Down

0 comments on commit 9c90b35

Please sign in to comment.