From da6d166a67aa1a9b1bce3e11acc9c368828859c9 Mon Sep 17 00:00:00 2001 From: jindaxiang Date: Mon, 1 Apr 2024 19:28:46 +0800 Subject: [PATCH] docs: update docs --- .github/workflows/ci.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index db9cac8..d910700 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,8 +27,12 @@ jobs: git config user.name "github-actions[bot]" - name: Deploy MkDocs site run: | - git config pull.rebase true - git pull origin gh-pages + if git ls-remote --exit-code --heads origin gh-pages > /dev/null 2>&1; then + git config pull.rebase true + git pull origin gh-pages + else + echo "gh-pages branch does not exist yet. Skipping pull." + fi version=$(date +%Y.%m.%d) mike deploy --push --update-aliases $version latest mike set-default --push latest