Skip to content

Commit 497cde7

Browse files
authored
[Actions] Updating deprecated actions, removing unnecessary checkouts, adding workflow dispatch call (#351)
* Make sure that this workflow will be triggered on a test branch * Removing the checkout of Thunder since it should no longer be necessary after last changes * Updating all actions to Node.js 20 * Updating more actions to newest version * Updating Windows actions to newest version * Adding workflow_dispatch to be able to trigger the action manually * Triggering a template from my branch to test it * Adding branch restriction back and using templates from masters * Adding branch restriction back for Windows build
1 parent 957c0b5 commit 497cde7

File tree

3 files changed

+22
-22
lines changed

3 files changed

+22
-22
lines changed

.github/workflows/Build ThunderInterfaces on Linux.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: Build ThunderInterfaces on Linux
22

33
on:
4+
workflow_dispatch:
45
push:
56
branches: ["master"]
67
pull_request:

.github/workflows/Build ThunderInterfaces on Windows.yml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: Build ThunderInterfaces on Windows
22

33
on:
4+
workflow_dispatch:
45
push:
56
branches: ["master"]
67
pull_request:
@@ -23,48 +24,50 @@ jobs:
2324

2425
name: Build type - ${{matrix.type}}${{matrix.version}}
2526
steps:
27+
# ----- Checkout -----
2628
- name: Checkout ThunderOnWindows
27-
uses: actions/checkout@v3
29+
uses: actions/checkout@v4
2830
with:
2931
path: ThunderOnWindows
3032
repository: WebPlatformForEmbedded/ThunderOnWindows
3133

3234
- name: Checkout Thunder
33-
uses: actions/checkout@v3
35+
uses: actions/checkout@v4
3436
with:
3537
path: ThunderOnWindows/Thunder
3638
repository: ${{github.repository_owner}}/Thunder
3739

3840
- name: Checkout ThunderTools
39-
uses: actions/checkout@v3
41+
uses: actions/checkout@v4
4042
with:
4143
path: ThunderOnWindows/ThunderTools
4244
repository: ${{github.repository_owner}}/ThunderTools
4345

4446
- name: Checkout ThunderClientLibraries
45-
uses: actions/checkout@v3
47+
uses: actions/checkout@v4
4648
with:
4749
path: ThunderOnWindows/ThunderClientLibraries
4850
repository: ${{github.repository_owner}}/ThunderClientLibraries
4951

5052
- name: Checkout ThunderInterfaces
51-
uses: actions/checkout@v3
53+
uses: actions/checkout@v4
5254
with:
5355
path: ThunderOnWindows/ThunderInterfaces
5456
repository: ${{github.repository_owner}}/ThunderInterfaces
5557

5658
- name: Checkout ThunderNanoServices
57-
uses: actions/checkout@v3
59+
uses: actions/checkout@v4
5860
with:
5961
path: ThunderOnWindows/ThunderNanoServices
6062
repository: ${{github.repository_owner}}/ThunderNanoServices
6163

6264
- name: Checkout ThunderNanoServicesRDK
63-
uses: actions/checkout@v3
65+
uses: actions/checkout@v4
6466
with:
6567
path: ThunderOnWindows/ThunderNanoServicesRDK
6668
repository: WebPlatformForEmbedded/ThunderNanoServicesRDK
6769

70+
# ----- Building -----
6871
- name: Install jsonref
6972
run: pip install jsonref
7073

@@ -74,12 +77,13 @@ jobs:
7477
cd ThunderOnWindows
7578
&& "%devEnv%" /Build "${{matrix.type}}|x${{matrix.version}}" /Project "%definitions%" "%solution%"
7679
&& "%devEnv%" /Build "${{matrix.type}}|x${{matrix.version}}" /Project "%interfaces%" "%solution%"
77-
80+
81+
# ----- Articats -----
7882
- name: Tar files
7983
run: tar -czvf ${{matrix.type}}${{matrix.version}}.tar.gz artifacts
8084

8185
- name: Upload
82-
uses: actions/upload-artifact@v3
86+
uses: actions/upload-artifact@v4
8387
with:
8488
name: ThunderInterfaces-${{matrix.type}}${{matrix.version}}-artifact
8589
path: ${{matrix.type}}${{matrix.version}}.tar.gz

.github/workflows/Linux build template.yml

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,11 @@ jobs:
1212
matrix:
1313
build_type: [Debug, Release, MinSizeRel]
1414

15+
# ----- Packages & artifacts -----
1516
name: Build type - ${{matrix.build_type}}
1617
steps:
1718
- name: Install necessary packages
18-
uses: nick-fields/retry@v2
19+
uses: nick-fields/retry@v3
1920
with:
2021
timeout_minutes: 10
2122
max_attempts: 10
@@ -27,14 +28,8 @@ jobs:
2728
pip install jsonref
2829
sudo apt install build-essential cmake ninja-build libusb-1.0-0-dev zlib1g-dev libssl-dev
2930
30-
- name: Checkout Thunder
31-
uses: actions/checkout@v3
32-
with:
33-
path: Thunder
34-
repository: rdkcentral/Thunder
35-
3631
- name: Download artifacts
37-
uses: actions/download-artifact@v3
32+
uses: actions/download-artifact@v4
3833
with:
3934
name: Thunder-${{matrix.build_type}}-artifact
4035
path: ${{matrix.build_type}}
@@ -44,10 +39,10 @@ jobs:
4439
tar -xvzf ${{matrix.build_type}}/${{matrix.build_type}}.tar.gz
4540
rm ${{matrix.build_type}}/${{matrix.build_type}}.tar.gz
4641
47-
# ----- ThunderInterfaces -----
42+
# ----- Regex & checkout -----
4843
- name: Checkout ThunderInterfaces - default
4944
if: ${{ !contains(github.event.pull_request.body, '[DependsOn=ThunderInterfaces:') }}
50-
uses: actions/checkout@v3
45+
uses: actions/checkout@v4
5146
with:
5247
path: ThunderInterfaces
5348
repository: rdkcentral/ThunderInterfaces
@@ -63,13 +58,13 @@ jobs:
6358

6459
- name: Checkout ThunderInterfaces - ${{steps.thunderinterfaces.outputs.first_match}}
6560
if: contains(github.event.pull_request.body, '[DependsOn=ThunderInterfaces:')
66-
uses: actions/checkout@v3
61+
uses: actions/checkout@v4
6762
with:
6863
path: ThunderInterfaces
6964
repository: rdkcentral/ThunderInterfaces
7065
ref: ${{steps.thunderinterfaces.outputs.first_match}}
7166

72-
# ----- Building -----
67+
# ----- Building & uploading -----
7368
- name: Build ThunderInterfaces
7469
run: |
7570
cmake -G Ninja -S ThunderInterfaces -B ${{matrix.build_type}}/build/ThunderInterfaces \
@@ -82,7 +77,7 @@ jobs:
8277
run: tar -czvf ${{matrix.build_type}}.tar.gz ${{matrix.build_type}}
8378

8479
- name: Upload
85-
uses: actions/upload-artifact@v3
80+
uses: actions/upload-artifact@v4
8681
with:
8782
name: ThunderInterfaces-${{matrix.build_type}}-artifact
8883
path: ${{matrix.build_type}}.tar.gz

0 commit comments

Comments
 (0)