Skip to content

Commit a8ed04c

Browse files
author
Austin Bingham
committed
Adding version bump to GHA.
1 parent c63fbda commit a8ed04c

File tree

2 files changed

+51
-16
lines changed

2 files changed

+51
-16
lines changed

.github/workflows/bump_version.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Bump version
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
bump-type:
7+
description: "Bump type"
8+
required: true
9+
default: "patch"
10+
type: choice
11+
options:
12+
- major
13+
- minor
14+
- patch
15+
16+
jobs:
17+
build:
18+
runs-on: ubuntu-latest
19+
steps:
20+
- name: Checkout the code
21+
uses: actions/checkout@v4
22+
23+
- name: Bump version
24+
id: bump
25+
uses: callowayproject/bump-my-version@master
26+
env:
27+
BUMPVERSION_TAG: "true"
28+
with:
29+
args: ${{ inputs.bump-type }}
30+
# github-token: ${{ secrets.GH_TOKEN }}
31+
32+
- name: Check
33+
if: steps.bump.outputs.bumped == 'true'
34+
run: |
35+
echo "Version was bumped from ${{ steps.bump.outputs.previous-version }} to ${{ steps.bump.outputs.current-version }}!"
Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -31,19 +31,19 @@ jobs:
3131
- name: "Check coverage"
3232
run: uv run coverage report --show-missing --fail-under=100
3333

34-
package:
35-
name: "Build Package Distributions"
36-
needs: tests
37-
runs-on: "ubuntu-latest"
38-
steps:
39-
- uses: "actions/checkout@v3"
40-
- name: Install uv
41-
uses: astral-sh/setup-uv@v5
42-
- name: Build package
43-
run: uv build --wheel
44-
- name: Publish package
45-
if: startsWith(github.ref, 'refs/tags/release/v')
46-
uses: pypa/gh-action-pypi-publish@release/v1
47-
with:
48-
user: __token__
49-
password: ${{ secrets.PYPI_API_TOKEN }}
34+
# package:
35+
# name: "Build Package Distributions"
36+
# needs: tests
37+
# runs-on: "ubuntu-latest"
38+
# steps:
39+
# - uses: "actions/checkout@v3"
40+
# - name: Install uv
41+
# uses: astral-sh/setup-uv@v5
42+
# - name: Build package
43+
# run: uv build --wheel
44+
# - name: Publish package
45+
# if: startsWith(github.ref, 'refs/tags/release/v')
46+
# uses: pypa/gh-action-pypi-publish@release/v1
47+
# with:
48+
# user: __token__
49+
# password: ${{ secrets.PYPI_API_TOKEN }}

0 commit comments

Comments
 (0)