Unverified Commit 99d09c82 authored by paoloredis's avatar paoloredis Committed by GitHub
Browse files

Only run redis_docs_sync.yaml on latest release (#13603)

We only want to trigger the workflow on the documentation repository for
the latest release
parent 6c5e263d
...@@ -21,4 +21,15 @@ jobs: ...@@ -21,4 +21,15 @@ jobs:
GH_TOKEN: ${{ steps.generate-token.outputs.token }} GH_TOKEN: ${{ steps.generate-token.outputs.token }}
RELEASE_NAME: ${{ github.event.release.tag_name }} RELEASE_NAME: ${{ github.event.release.tag_name }}
run: | run: |
gh workflow run -R redis/docs redis_docs_sync.yaml -f release="${RELEASE_NAME}" LATEST_RELEASE=$(
\ No newline at end of file curl -Ls \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${GH_TOKEN}" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/redis/redis/releases/latest \
| jq -r '.tag_name'
)
if [[ "${LATEST_RELEASE}" == "${RELEASE_NAME}" ]]; then
gh workflow run -R redis/docs redis_docs_sync.yaml -f release="${RELEASE_NAME}"
fi
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment