From 70bdb1b19e56019d0b7134cb8d137052486acfa4 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 26 Nov 2025 02:13:14 +0000 Subject: [PATCH 1/3] Initial plan From 7bc6707ac33cc550d023a45e35410807e49c696c Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 26 Nov 2025 02:15:59 +0000 Subject: [PATCH 2/3] Make docs workflow idempotent by handling existing alias error Co-authored-by: hzhangxyz <11623447+hzhangxyz@users.noreply.github.com> --- .github/workflows/docs.yml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index eaf7125..886b8ca 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -31,7 +31,21 @@ jobs: git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: build docs - run: mike deploy --push ${GITHUB_REF#refs/tags/} latest + run: | + set -e + VERSION=${GITHUB_REF#refs/tags/} + TMP_OUT=$(mktemp) + trap 'rm -f "$TMP_OUT"' EXIT + if mike deploy --push "$VERSION" latest >"$TMP_OUT" 2>&1; then + echo "mike deploy succeeded" + else + if grep -q "alias 'latest' already exists" "$TMP_OUT"; then + echo "alias 'latest' already exists for this version; continuing" + else + cat "$TMP_OUT" + exit 1 + fi + fi - name: set default run: mike set-default --push latest From 9206908d7e076c525ae8ec3880d99aeac93ffb73 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 26 Nov 2025 02:22:07 +0000 Subject: [PATCH 3/3] Use --update-aliases flag instead of error handling script Co-authored-by: hzhangxyz <11623447+hzhangxyz@users.noreply.github.com> --- .github/workflows/docs.yml | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 886b8ca..3330302 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -31,21 +31,7 @@ jobs: git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: build docs - run: | - set -e - VERSION=${GITHUB_REF#refs/tags/} - TMP_OUT=$(mktemp) - trap 'rm -f "$TMP_OUT"' EXIT - if mike deploy --push "$VERSION" latest >"$TMP_OUT" 2>&1; then - echo "mike deploy succeeded" - else - if grep -q "alias 'latest' already exists" "$TMP_OUT"; then - echo "alias 'latest' already exists for this version; continuing" - else - cat "$TMP_OUT" - exit 1 - fi - fi + run: mike deploy --push --update-aliases ${GITHUB_REF#refs/tags/} latest - name: set default run: mike set-default --push latest