test
This commit is contained in:
1 parent
276a583e7a
commit
d5efc91eea
1 file changed
+7
-3
@@ -14,6 +14,7 @@ jobs:
|
|||||||
- name: Check
|
- name: Check
|
||||||
run: echo "Checking for new releases ..."
|
run: echo "Checking for new releases ..."
|
||||||
- name: Check for new releases in target repository
|
- name: Check for new releases in target repository
|
||||||
|
id: check_release
|
||||||
run: |
|
run: |
|
||||||
echo "--- Checking ${TARGET_REPO_OWNER}/${TARGET_REPO_NAME} for new releases ---"
|
echo "--- Checking ${TARGET_REPO_OWNER}/${TARGET_REPO_NAME} for new releases ---"
|
||||||
|
|
||||||
@@ -24,7 +25,7 @@ jobs:
|
|||||||
|
|
||||||
# Check if API call failed or returned no data
|
# Check if API call failed or returned no data
|
||||||
if [ "$API_OUTPUT" == '[]' ]; then
|
if [ "$API_OUTPUT" == '[]' ]; then
|
||||||
echo "⚠️ No releases found in the target repository."
|
echo "::error:: No releases found in the target repository."
|
||||||
exit 0 # Exit successfully, but do nothing.
|
exit 0 # Exit successfully, but do nothing.
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -34,11 +35,14 @@ jobs:
|
|||||||
LATEST_TAG=$(echo "${API_OUTPUT}" | jq -r '.[0].tag_name')
|
LATEST_TAG=$(echo "${API_OUTPUT}" | jq -r '.[0].tag_name')
|
||||||
PUBLISH_DATE=$(echo "${API_OUTPUT}" | jq -r '.[0].published_at')
|
PUBLISH_DATE=$(echo "${API_OUTPUT}" | jq -r '.[0].published_at')
|
||||||
|
|
||||||
echo "✅ Found latest version: ${LATEST_TAG} published on ${PUBLISH_DATE}"
|
echo "::error:: Found latest version: ${LATEST_TAG} published on ${PUBLISH_DATE}"
|
||||||
|
|
||||||
|
echo "::set-output name=latest_tag::${LATEST_TAG}"
|
||||||
|
echo "::set-output name=publish_date::${PUBLISH_DATE}"
|
||||||
|
|
||||||
- name: Download latest release
|
- name: Download latest release
|
||||||
run: |
|
run: |
|
||||||
DOWNLOAD_URL="https://github.com/prefix-dev/pixi/releases/download/v${LATEST_TAG}/pixi-x86_64-unknown-linux-musl.tar.gz"
|
DOWNLOAD_URL="https://github.com/prefix-dev/pixi/releases/download/v${{ steps.check_release.outputs.latest_tag }}/pixi-x86_64-unknown-linux-musl.tar.gz"
|
||||||
|
|
||||||
echo "Downloading latest release from $DOWNLOAD_URL ..."
|
echo "Downloading latest release from $DOWNLOAD_URL ..."
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user