| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- name: Push action
- on: [push]
- jobs:
- pre-commit:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- - name: Add pipx to PATH
- run: echo "/root/.local/bin" >> $GITHUB_PATH
- - name: Setup cache
- uses: actions/cache@v3
- with:
- path: |
- /opt/hostedtoolcache
- ~/.local/pipx
- /root/.local/bin
- key: ${{ runner.os }}-toolcache
- - name: Install pre-commit
- run: pipx install pre-commit --force
- - uses: actions/cache@v3
- with:
- path: ~/.cache/pre-commit
- key: pre-commit-3|${{ env.pythonLocation }}|${{ steps.get-hash-pre-commit.outputs.hash }}
- - run: pre-commit run --all-files --show-diff-on-failure --color=always ${{ inputs.extra_args }}
- shell: bash
- semantic-release:
- runs-on: ubuntu-latest
- needs:
- - pre-commit
- if: github.ref == 'refs/heads/main'
- steps:
- - name: Checkout
- uses: actions/checkout@v4
- - name: Add pipx to PATH
- run: echo "/root/.local/bin" >> $GITHUB_PATH
- - uses: actions/setup-node@v4
- with:
- node-version: "22.9.0"
- - name: Setup cache
- uses: actions/cache@v3
- with:
- path: |
- ~/.local/pipx
- /root/.local/bin
- key: ${{ runner.os }}-semantic-release-toolcache
- - name: Install poetry
- run: pipx install poetry --force
- - name: Semantic Release
- id: release
- uses: https://github.com/cycjimmy/semantic-release-action@v4
- with:
- extra_plugins: |
- @saithodev/semantic-release-gitea
- @bjoluc/semantic-release-config-poetry
- @semantic-release/git
- @semantic-release/changelog
- @semantic-release/exec
- @google/semantic-release-replace-plugin
- prettier
- env:
- GITEA_URL: ${{ github.server_url }}
- GITEA_TOKEN: ${{ secrets.SEMANTIC_RELEASE_TOKEN }}
|