Skip to content

Commit 286d2d9

Browse files
committed
separate file
1 parent bbb058a commit 286d2d9

2 files changed

Lines changed: 31 additions & 11 deletions

File tree

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: versionbump
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
- main
8+
pull_request:
9+
branches:
10+
- master
11+
- main
12+
release:
13+
types:
14+
- released
15+
16+
jobs:
17+
build:
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v2
21+
- name: Bump version
22+
run: |
23+
git config --global user.name 'ProjectBot'
24+
git config --global user.email 'bot@users.noreply.github.com'
25+
VERSION=$(sed -n '0,/.*<Version>\(.*\)<\/Version>.*/s//\1/p' module.xml)
26+
VERSION=`echo $VERSION | awk -F. '/[0-9]+\./{$NF++;print}' OFS=.`
27+
sed -i "0,/<Version>\(.*\)<\/Version>/s//<Version>$VERSION<\/Version>/" module.xml
28+
git add module.xml
29+
git commit -m 'auto bump version'
30+
git push

.github/workflows/runtests.yml

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,4 @@ jobs:
2525
push: false
2626
load: true
2727
tags: ${{ github.repository }}:${{ github.sha }}
28-
build-args: TESTS=1
29-
- name: Bump version
30-
run: |
31-
git config --global user.name 'ProjectBot'
32-
git config --global user.email 'bot@users.noreply.github.com'
33-
VERSION=$(sed -n '0,/.*<Version>\(.*\)<\/Version>.*/s//\1/p' module.xml)
34-
VERSION=`echo $VERSION | awk -F. '/[0-9]+\./{$NF++;print}' OFS=.`
35-
sed -i "0,/<Version>\(.*\)<\/Version>/s//<Version>$VERSION<\/Version>/" module.xml
36-
git add module.xml
37-
git commit -m 'auto bump version'
38-
git push
28+
build-args: TESTS=1

0 commit comments

Comments
 (0)