File: pre-release.yml

package info (click to toggle)
python-pipx 1.10.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 1,768 kB
  • sloc: python: 9,813; makefile: 17; sh: 7
file content (44 lines) | stat: -rw-r--r-- 1,203 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: Pre-release
on:
  workflow_dispatch:
    inputs:
      bump:
        description: "Version bump type"
        required: true
        type: choice
        options:
          - auto
          - major
          - minor
          - patch
        default: auto

env:
  default-python: "3.13"

jobs:
  pre-release:
    runs-on: ubuntu-latest
    environment: release
    permissions:
      contents: write
    steps:
      - name: Checkout code
        uses: actions/checkout@v6
        with:
          fetch-depth: 0
          token: ${{ secrets.GH_RELEASE_TOKEN }}
      - name: Set up Python ${{ env.default-python }}
        uses: actions/setup-python@v6
        with:
          python-version: ${{ env.default-python }}
      - name: Install dependencies
        run: |
          python -m pip install --upgrade pip
          pip install GitPython packaging towncrier pre-commit
      - name: Configure git identity
        run: |
          git config user.name "github-actions[bot]"
          git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
      - name: Generate changelog, commit, tag, and push
        run: python scripts/release.py --version "${{ inputs.bump }}"