build: bump the actions group with 3 updates (#249) #249
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release Drafter | |
| on: | |
| push: | |
| branches: | |
| - "main" | |
| workflow_dispatch: | |
| jobs: | |
| draft-release: | |
| permissions: | |
| # write permission is required to create a github release | |
| contents: write | |
| # write permission is required for autolabeler | |
| # otherwise, read permission is required at least | |
| pull-requests: write | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 | |
| - name: Generate release notes header | |
| run: | | |
| echo "## 💡 Default Clang Tool Versions" > release_notes.md | |
| echo "" >> release_notes.md | |
| echo "Versions are resolved dynamically from PyPI at hook runtime, always using the latest stable release by default. " >> release_notes.md | |
| echo "You can pin a specific version by adding the \`--version\` argument under \`args\` in your pre-commit config." >> release_notes.md | |
| echo "See [Custom Clang Tool Version](https://github.com/cpp-linter/cpp-linter-hooks?tab=readme-ov-file#custom-clang-tool-version) for details." >> release_notes.md | |
| echo "" >> release_notes.md | |
| cat release_notes.md | |
| # Export release notes content to env variable for Release Drafter | |
| echo "RELEASE_BODY<<EOF" >> $GITHUB_ENV | |
| cat release_notes.md >> $GITHUB_ENV | |
| echo "EOF" >> $GITHUB_ENV | |
| # Draft your next Release notes as Pull Requests are merged into the default branch | |
| - uses: release-drafter/release-drafter@4d75298e00d9e34c483e5ff8c68d0ea1c1940c1e # v7.5.1 | |
| with: | |
| commitish: 'main' | |
| header: ${{ env.RELEASE_BODY }} | |
| config-name: github:cpp-linter/.github:/.github/release-drafter.yml | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |