minor correction
All checks were successful
continuous-integration/drone Build is passing

This commit is contained in:
2025-09-07 16:59:06 +05:30
parent 8ec6c7652a
commit 68add3b228

View File

@@ -66,13 +66,20 @@ steps:
commands:
- apk add jq curl
- |
LATEST_TAG=$(curl -s "https://gitea.akshun-lab.cc/api/v1/repos/aggarwalakshun/python-setup/releases/latest" | jq -r '.tag_name')
# Get the latest release information
RELEASE_INFO=$(curl -s "https://gitea.akshun-lab.cc/api/v1/repos/aggarwalakshun/python-setup/releases/latest")
LATEST_TAG=$(echo "$RELEASE_INFO" | jq -r '.tag_name')
RELEASE_ID=$(echo "$RELEASE_INFO" | jq -r '.id')
echo "Latest tag: $LATEST_TAG"
echo "Release ID: $RELEASE_ID"
for file in /artifacts/*-setup; do
FILENAME=$(basename "$file")
echo "Uploading $FILENAME..."
curl -X POST "https://gitea.akshun-lab.cc/api/v1/repos/aggarwalakshun/python-setup/releases/$LATEST_TAG/assets?name=$FILENAME" \
# Use the release ID instead of tag name in the URL
curl -X POST "https://gitea.akshun-lab.cc/api/v1/repos/aggarwalakshun/python-setup/releases/$RELEASE_ID/assets?name=$FILENAME" \
-H "Authorization: token $GITEA_TOKEN" \
-H "Content-Type: application/octet-stream" \
--data-binary @"$file"