diff --git a/.github/workflows/static.yml b/.github/workflows/static.yml index a8cfc77..09f1704 100644 --- a/.github/workflows/static.yml +++ b/.github/workflows/static.yml @@ -31,6 +31,8 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 + with: + fetch-depth: 0 - name: 运行部署脚本 run: python3 deploy.py diff --git a/deploy.py b/deploy.py index f68c68d..2dbcee2 100644 --- a/deploy.py +++ b/deploy.py @@ -43,7 +43,7 @@ def get_env_info() -> dict[str, str]: env_info["message"] = message.stdout.strip() # git tag if ON_CF: - tag = os.getenv("CF_PAGES_COMMIT_TAG") or "cf" + tag = os.getenv("CF_PAGES_COMMIT_TAG") or "cf_deploy" else: tag = run( ["git", "describe", "--tags"], capture_output=True, text=True, encoding="utf-8"