-
-
Notifications
You must be signed in to change notification settings - Fork 35
46 lines (43 loc) · 1.25 KB
/
release.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
name: Tag and Release
on: workflow_dispatch
jobs:
change-version:
runs-on: ubuntu-latest
outputs:
version: ${{ steps.document.outputs.version }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: 11
- uses: DeLaGuardo/setup-clojure@master
with:
cli: latest
- uses: actions/cache@v4
with:
path: ~/.m2
key: clojure-m2-${{ hashFiles('deps.edn') }}
- name: Update and commit version file
id: document
run: |
clojure -T:build update-documents
git diff
git config --global user.email "[email protected]"
git config --global user.name "github-actions"
git add -A
git commit -m "Update for release [skip ci]" || exit 0
git push
tag-and-release:
needs: [change-version]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: git pull origin main
- uses: ncipollo/release-action@v1
with:
tag: ${{ needs.change-version.outputs.version }}
skipIfReleaseExists: true
generateReleaseNotes: true