Skip to content

Commit d9f947a

Browse files
authored
feat: add docker repo automation
1 parent 129a6ba commit d9f947a

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/main.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Tag a new seat-docker release
2+
on:
3+
release:
4+
types: [released]
5+
# Allows you to run this workflow manually from the Actions tab
6+
workflow_dispatch:
7+
8+
jobs:
9+
build:
10+
name: Checkout and tag
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
with:
15+
repository: eveseat/seat-docker
16+
ssh-key: '${{ secrets.SEAT_DOCKER_REPO }}'
17+
- run: |
18+
git config user.name github-actions
19+
git config user.email github-actions@github.com
20+
currver=`cat version`
21+
a=(${currver//./ })
22+
newrelease=${a[2]}
23+
newrelease=$((newrelease+1))
24+
newver="${a[0]}.${a[1]}.${newrelease}"
25+
echo $newver > version
26+
git add version
27+
git commit -m "bump to version $newver"
28+
git push
29+
git tag -a "$newver" -m "src: $GITHUB_REPOSITORY commit: ${GITHUB_SHA: -8}"
30+
git push origin --tags
31+

0 commit comments

Comments
 (0)