-
-
Notifications
You must be signed in to change notification settings - Fork 104
69 lines (60 loc) · 2.06 KB
/
bundle_latest.yml
File metadata and controls
69 lines (60 loc) · 2.06 KB
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
# SPDX-FileCopyrightText: 2025 Howetuft, Johannes Hinrichs (CodeFHD)
#
# SPDX-License-Identifier: GPL-3.0-or-later
name: BlendLuxCore Create Latest Release
on:
workflow_dispatch:
jobs:
build_latest:
name: Build Latest Bundle
uses: ./.github/workflows/build_bundle.yml
with:
build_type: "Latest"
create_release:
name: Create Latest Release
runs-on: ubuntu-latest
needs: build_latest
steps:
- name: Checkout main repository
uses: actions/checkout@v4
- name: Get Bundle
uses: actions/download-artifact@v4
with:
name: "BlendLuxCore"
path: "${{ github.workspace }}/download/"
- name: Update the "latest" tag
uses: richardsimko/update-tag@v1
with:
tag_name: latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Delete old latest release
shell: bash
run: |
echo "Delete old latest release"
echo false > ${{ github.workspace }}/tmp_release_test
gh release list --json name > ${{ github.workspace }}/tmp_releases
jq -r -c .[].name ${{ github.workspace }}/tmp_releases | while read i; do
echo $i
if [[ "$i" = "latest" ]]; then
echo "FOUND"
echo true > "${{ github.workspace }}/tmp_release_test"
fi
done
TESTRESULT=$(cat ${{ github.workspace }}/tmp_release_test)
echo RESULT
echo $TESTRESULT
if [[ $TESTRESULT = 'true' ]]; then
echo DELETE
gh release delete latest
fi
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Create new release
uses: softprops/action-gh-release@v2
with:
tag_name: latest
files: "${{ github.workspace }}/download/BlendLuxCore-*.zip"
draft: false
prerelease: true
body: "This is the result of automatic compilation of the latest commits.\n\nPlease note that this release may be unstable and is not recommended for production use."