-
-
Notifications
You must be signed in to change notification settings - Fork 3
41 lines (35 loc) · 1.17 KB
/
devel.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
name: Development
on:
workflow_dispatch:
jobs:
version:
name: Version
runs-on: ubuntu-latest
outputs:
tag_abbrev: ${{ steps.version.outputs.tag_abbrev }}
tag_offset: ${{ steps.version.outputs.tag_offset }}
sha_short: ${{ steps.version.outputs.sha_short }}
full_desc: ${{ steps.version.outputs.full_desc }}
branch: ${{ steps.version.outputs.branch }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- name: Version
id: version
shell: bash
run: |
tag_abbrev=$(git describe --tags --abbrev=0)
echo "tag_abbrev=$tag_abbrev" >> $GITHUB_OUTPUT
echo "tag_offset=$(git rev-list $tag_abbrev..HEAD --count)" >> $GITHUB_OUTPUT
echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
echo "full_desc=$(git describe --long --tags)" >> $GITHUB_OUTPUT
echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
build:
needs: version
name: Build
uses: ./.github/workflows/build.yml
with:
name: ${{ needs.version.outputs.full_desc }}-${{ needs.version.outputs.branch }}