-
Notifications
You must be signed in to change notification settings - Fork 1
70 lines (61 loc) · 1.85 KB
/
auto-release-tools.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
name: "release additional tools"
on:
push:
paths:
- dcc_plugins*/**
- src/lifeblood_client/**
branches:
- dev
- master
jobs:
build_all_tools:
uses: ./.github/workflows/build-tools.yml
make_tool_release:
needs:
- build_all_tools
runs-on: ubuntu-latest
outputs:
tag: ${{ steps.derive_tag.outputs.tag }}
steps:
- uses: actions/checkout@v4
with:
path: repo
fetch-depth: 0 # to fetch all history, not just a single commit
- id: derive_tag
run: |
git config --global user.email "actions@github.com"
git config --global user.name "Tools auto tag"
git checkout ${{ github.sha }}
git tag
git branch --all
git log -n5
TAG="$(git describe)-tools"
echo "TAG=$TAG" >> $GITHUB_ENV
echo "tag=$TAG" >> "$GITHUB_OUTPUT"
echo "new tag is $TAG"
git tag -a $TAG -m 'tools autobuild update'
git push origin $TAG
working-directory: ./repo
- uses: actions/download-artifact@v4
with:
path:
tools
- run: |
ls -alR tools
echo tag would be $TAG
- uses: softprops/action-gh-release@v2
with:
tag_name: ${{ env.TAG }}
files:
tools/*/*
notify:
uses: ./.github/workflows/release-notify.yml
secrets:
TELEGRAM_INFO_BOT_ID: ${{ secrets.TELEGRAM_INFO_BOT_ID }}
TELEGRAM_INFO_CHANNEL_ID: ${{ secrets.TELEGRAM_INFO_CHANNEL_ID }}
with:
message_prepend: "🔧 dcc plugins autoupdate ${{ needs.make_tool_release.outputs.tag }}!\n"
message_append: |-
https://github.com/${{ github.repository}}/releases/tag/${{ needs.make_tool_release.outputs.tag }}
#tools
needs: [ "make_tool_release" ]