-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
52 lines (42 loc) · 1.58 KB
/
action.yml
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
45
46
47
48
49
50
51
52
name: Bump PyPi Version
description: Bumps the patch number of a PyPi package and commits the change back to the main branch.
icon: arrow-right
ICON: 'github'
COLOR: blue
on:
push:
branches:
- master
jobs:
bump-version:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
# This is a Personal Acess Token for your github account can be created from the link below
# https://docs.github.com/en/github/authenticating-to-github/keeping-your-account-and-data-secure/creating-a-personal-access-token
token: ${{ secrets.PAT }} # This is a Personal Acess Token from
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
- name: Setup Git
run: |
git config user.name "Benedict-Carling"
git config user.email '[email protected]'
git remote set-url origin https://x-access-token:${{ secrets.PAT }}@github.com/Benedict-Carling/spanish-conjugator
git checkout master
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install bump2version setuptools wheel twine
- name: Bump Patch Version
env:
COMMIT_MSG: ${{ github.event.head_commit.message }}
run: |
bump2version --current-version $(python setup.py --version ) patch setup.py
- name: Commit version change to master - Push
# Skip CI tag is import below otherwise it would trigger continous version bumps
run: |
git commit -am "[skip ci]Automated version bump"
git push