From 51ca82c7cf116f1fa0a6dabe024279540e5911ff Mon Sep 17 00:00:00 2001 From: Sergey Shelomentsev Date: Wed, 27 Mar 2024 11:54:14 +0200 Subject: [PATCH] chore: use dx-toolkit for analyzing commits --- .github/workflows/analyze-commits.yml | 64 +++------------------------ 1 file changed, 5 insertions(+), 59 deletions(-) diff --git a/.github/workflows/analyze-commits.yml b/.github/workflows/analyze-commits.yml index 7d4c167..6c78cb9 100644 --- a/.github/workflows/analyze-commits.yml +++ b/.github/workflows/analyze-commits.yml @@ -1,65 +1,11 @@ name: Analyze Commit Messages -on: [pull_request] +on: + pull_request: permissions: pull-requests: write contents: write jobs: - commitlint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: wagoid/commitlint-github-action@v5 - id: commitlint - - if: ${{ failure() && steps.commitlint.outcome == 'failure' }} - uses: marocchino/sticky-pull-request-comment@3d60a5b2dae89d44e0c6ddc69dd7536aec2071cd - with: - header: Commitlint - recreate: true - message: | - ## Wrong commit message format detected - We use [Semantic Commit Messages](https://gist.github.com/joshbuchea/6f47e86d2510bce28f8e7f42ae84c716) in our project. - - > **Warning** - > Probably you forgot to activate local git hooks. - - Run the next command in the project root to activate local hooks: - ```sh - sh ./install_hooks.sh - ``` - - More info you can find in [job logs](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}) - - if: ${{ success() }} - uses: marocchino/sticky-pull-request-comment@3d60a5b2dae89d44e0c6ddc69dd7536aec2071cd - with: - header: Commitlint - hide: true - hide_classify: "OUTDATED" - release-notes-comment: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - name: Collect semantic-release-info - id: semantic_release_info - uses: fingerprintjs/action-semantic-release-info@v1 - - if: ${{ steps.semantic_release_info.outputs.no_release == 'false' }} - name: Add comment to the PR - uses: marocchino/sticky-pull-request-comment@3d60a5b2dae89d44e0c6ddc69dd7536aec2071cd - with: - header: ReleasePreview - recreate: true - message: | - ## This PR will create a ${{steps.semantic_release_info.outputs.type}} release :rocket: - ${{steps.semantic_release_info.outputs.notes}} - - if: ${{ steps.semantic_release_info.outputs.no_release == 'true' }} - name: Add comment to the PR - uses: marocchino/sticky-pull-request-comment@3d60a5b2dae89d44e0c6ddc69dd7536aec2071cd - with: - header: ReleasePreview - recreate: true - message: | - ## This PR will not create a new release :rocket: + analyze-commits: + name: Generate docs and coverage report + uses: fingerprintjs/dx-team-toolkit/.github/workflows/analyze-commits.yml@v1