1+ name : Carbide Release new version
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+'
7+
8+ jobs :
9+ # ============================================================================
10+ # Fetch new version
11+ # ============================================================================
12+ fetch-new-version :
13+ runs-on : linux-amd64-cpu4
14+ outputs :
15+ version : ${{ steps.fetch.outputs.version }}
16+ steps :
17+ - name : Checkout code
18+ uses : actions/checkout@v4
19+ with :
20+ fetch-depth : 0
21+
22+ - name : Fetch version
23+ id : fetch
24+ run : |
25+ set -euo pipefail
26+
27+ VERSION=$(echo ${{ github.ref }} | grep -oE 'v[0-9]+\.[0-9]+\.[0-9]+')
28+
29+ # ============================================================================
30+ # Release new version
31+ # ============================================================================
32+ release-new-version-approve :
33+ runs-on : linux-amd64-cpu4
34+ environment :
35+ name : release-new-version-approve
36+ needs :
37+ - fetch-new-version
38+ steps :
39+ - name : Release new version
40+ run : echo "Releasing new version ${{ needs.fetch-new-version.outputs.version }} to NVIDIA Catalog"
41+
42+ # ============================================================================
43+ # Release new version
44+ # ============================================================================
45+ release-new-version :
46+ runs-on : linux-amd64-cpu4
47+ needs :
48+ - fetch-new-version
49+ - release-new-version-approve
50+ steps :
51+ - name : Checkout code
52+ uses : actions/checkout@v4
53+ with :
54+ fetch-depth : 0
55+ - name : Push Git Tag
56+ uses : NVIDIA/dsx-github-actions/.github/actions/git-tag@260d3f3e8f7c193a87f03d10646ca606165f916e
57+ with :
58+ tag : ${{ needs.fetch-new-version.outputs.version }}
59+ - name : Release
60+ uses : softprops/action-gh-release@v2
61+ if : github.ref_type == 'tag'
62+ with :
63+ name : ${{ needs.fetch-new-version.outputs.version }}
64+ tag_name : ${{ needs.fetch-new-version.outputs.version }}
0 commit comments