Skip to content

Commit ba2b44b

Browse files
committed
fixup gha
1 parent d0fc382 commit ba2b44b

File tree

2 files changed

+29
-28
lines changed

2 files changed

+29
-28
lines changed
Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
1+
12
on:
23
push:
3-
tags:
4-
- 'v*' # Triggers on version tags
4+
branches:
5+
- "master"
6+
pull_request:
7+
branches:
8+
- "*"
59

610
jobs:
711
tests:
@@ -21,26 +25,20 @@ jobs:
2125
env:
2226
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2327

24-
- name: Get tag version
28+
- name: Get version
2529
id: get_version
2630
run: |
2731
git config --global user.email "atlas-tests-bot@nim-lang.org"
2832
git config --global user.name "Atlas Tests Bot"
29-
# Strip the 'v' prefix from the tag
30-
VERSION=${GITHUB_REF#refs/tags/v}
33+
VERSION=$(nim --verbosity:0 atlasTestsVersion)
3134
echo "version=$VERSION" >> $GITHUB_OUTPUT
32-
35+
3336
- name: Build Tests
3437
run: |
38+
nim --verbosity:0 atlasTestsVersion
3539
nim atlasTestsCreate
3640
37-
- name: Create Release
38-
uses: softprops/action-gh-release@v1
41+
- uses: actions/upload-artifact@v4
3942
with:
40-
name: Release ${{ steps.get_version.outputs.version }}
41-
tag_name: v${{ steps.get_version.outputs.version }}
42-
draft: false
43-
prerelease: false
44-
generate_release_notes: true
45-
env:
46-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43+
name: atlas-tests
44+
path: atlas-tests.zip

.github/workflows/build-release.yml

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
1-
21
on:
32
push:
4-
branches:
5-
- "main"
6-
pull_request:
7-
branches:
8-
- "*"
3+
tags:
4+
- '**' # Triggers on version tags
95

106
jobs:
117
tests:
@@ -25,20 +21,27 @@ jobs:
2521
env:
2622
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2723

28-
- name: Get version
24+
- name: Get tag version
2925
id: get_version
3026
run: |
3127
git config --global user.email "atlas-tests-bot@nim-lang.org"
3228
git config --global user.name "Atlas Tests Bot"
33-
VERSION=$(nim --verbosity:0 atlasTestsVersion)
29+
# Strip the 'v' prefix from the tag
30+
VERSION=${GITHUB_REF#refs/tags/v}
3431
echo "version=$VERSION" >> $GITHUB_OUTPUT
35-
32+
3633
- name: Build Tests
3734
run: |
38-
nim --verbosity:0 atlasTestsVersion
3935
nim atlasTestsCreate
4036
41-
- uses: actions/upload-artifact@v4
37+
- name: Create Release
38+
uses: softprops/action-gh-release@v1
4239
with:
43-
name: atlas-tests
44-
path: atlas-tests.zip
40+
name: Release ${{ steps.get_version.outputs.version }}
41+
tag_name: v${{ steps.get_version.outputs.version }}
42+
draft: false
43+
prerelease: false
44+
generate_release_notes: true
45+
files: atlas-tests.zip
46+
env:
47+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)