Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 14 additions & 9 deletions .github/workflows/fork-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -167,16 +167,21 @@ jobs:
PREVIOUS_SHA: ${{ steps.previous.outputs.sha }}
run: |
deploy=true
if [[ "${PREVIOUS_SHA}" =~ ^[0-9a-f]{40}$ ]] &&
git fetch --quiet origin "${PREVIOUS_SHA}" &&
git cat-file -e "${PREVIOUS_SHA}^{commit}"; then
deploy="$(
scripts/classify-deployment-diff.sh "${PREVIOUS_SHA}" "${GITHUB_SHA}" |
tee /dev/stderr |
sed -n 's/^deploy=//p'
)"
if [[ "${PREVIOUS_SHA}" =~ ^[0-9a-f]{40}$ ]]; then
if ! git cat-file -e "${PREVIOUS_SHA}^{commit}" 2>/dev/null; then
git fetch --quiet origin "${PREVIOUS_SHA}" || true
fi
if git cat-file -e "${PREVIOUS_SHA}^{commit}" 2>/dev/null; then
deploy="$(
scripts/classify-deployment-diff.sh "${PREVIOUS_SHA}" "${GITHUB_SHA}" |
tee /dev/stderr |
sed -n 's/^deploy=//p'
)"
else
echo "Previous successful integration SHA is unavailable; deployment remains enabled."
fi
else
echo "No fetchable previous successful integration SHA; deployment remains enabled."
echo "No previous successful integration SHA; deployment remains enabled."
fi
echo "deploy=${deploy}" >>"${GITHUB_OUTPUT}"

Expand Down
Loading