From 8007bc5f800ed670893b2b02d2124eb2e92f558a Mon Sep 17 00:00:00 2001 From: wanghaoran Date: Sat, 13 Sep 2025 11:27:33 +0800 Subject: [PATCH] ci: fix semantic release skipped due to head conflict --- .github/workflows/generate-llm-txt.yml | 15 +-------------- .github/workflows/semantic-release.yml | 13 +++++++++---- 2 files changed, 10 insertions(+), 18 deletions(-) diff --git a/.github/workflows/generate-llm-txt.yml b/.github/workflows/generate-llm-txt.yml index 1868cd9..4f448b6 100644 --- a/.github/workflows/generate-llm-txt.yml +++ b/.github/workflows/generate-llm-txt.yml @@ -1,20 +1,7 @@ name: Generate LLM.txt on: - # Trigger on releases - release: - types: [published] - - # Trigger on pushes to main branch - push: - branches: [main] - paths: - - 'src/mcpm/commands/**' - - 'src/mcpm/cli.py' - - 'scripts/generate_llm_txt.py' - - # Allow manual trigger - workflow_dispatch: + workflow_call: jobs: generate-llm-txt: diff --git a/.github/workflows/semantic-release.yml b/.github/workflows/semantic-release.yml index dc3b7aa..aa4c7f0 100644 --- a/.github/workflows/semantic-release.yml +++ b/.github/workflows/semantic-release.yml @@ -1,32 +1,37 @@ name: Semantic Release on: - workflow_dispatch: push: branches: - main paths: - 'src/mcpm/**' - 'pyproject.toml' + workflow_dispatch: permissions: contents: write issues: write pull-requests: write - id-token: write # Required for PyPI trusted publishing + id-token: write # Required for PyPI trusted publishing jobs: + update-llm-txt: + name: Update LLM.txt + uses: ./.github/workflows/generate-llm-txt.yml + secrets: inherit + test: uses: ./.github/workflows/test.yml release: name: Release - needs: test + needs: [test, update-llm-txt] runs-on: ubuntu-latest environment: name: pypi url: https://pypi.org/p/mcpm - + steps: - name: Checkout uses: actions/checkout@v4