Skip to content

Commit 704a148

Browse files
committed
CI: use env.ImageOS instead of steps.image.output.os
this improves the commit 0f4ffe5 The /etc/environment ImageOS is already emitted to GitHub env with the commit a4c1268 so we can use that directly without the extra step. In coverity-scan.yml the environment was moved up to be set early (similarly as with other workflow files) because now the env.ImageOS is required earlier.
1 parent 2eb32bf commit 704a148

2 files changed

Lines changed: 9 additions & 15 deletions

File tree

‎.github/workflows/coverity-scan.yml‎

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@ jobs:
2525
run: |
2626
echo "secrets.coverity_token not present, skipping the analysis!"
2727
exit 1
28-
- name: Identify OS version
29-
id: image
30-
run: echo "os=${ImageOS?}" >> "$GITHUB_OUTPUT"
3128
3229
- name: Get Coverity tool name # the file name contains version and is used as the cache key
3330
id: tool
@@ -56,6 +53,8 @@ jobs:
5653
- uses: actions/checkout@main
5754
with:
5855
submodules: true
56+
- name: Set environment
57+
run: . .github/scripts/environment.sh
5958
- name: Fetch SDKs ETags
6059
id: etags
6160
run: |
@@ -72,26 +71,24 @@ jobs:
7271
uses: actions/cache@main
7372
with:
7473
path: '/var/tmp/ffmpeg'
75-
key: cache-ffmpeg-${{ github.workflow }}-${{ steps.image.outputs.os }}-${{
74+
key: cache-ffmpeg-${{ github.workflow }}-${{ env.ImageOS }}-${{
7675
hashFiles( '.github/scripts/Linux/install_ffmpeg.sh',
7776
'.github/scripts/Linux/install_other.sh',
7877
'.github/scripts/Linux/ffmpeg-patches/*') }}
7978
- name: Cache SDL
8079
uses: actions/cache@main
8180
with:
8281
path: '/var/tmp/sdl'
83-
key: cache-sdl-${{ github.workflow }}-${{ steps.image.outputs.os }}-${{ hashFiles(
82+
key: cache-sdl-${{ github.workflow }}-${{ env.ImageOS }}-${{ hashFiles(
8483
'.github/scripts/Linux/install_sdl.sh' ) }}
8584
- name: Cache GLFW
8685
uses: actions/cache@main
8786
with:
8887
path: '/var/tmp/glfw'
89-
key: cache-glfw-${{ github.workflow }}-${{ steps.image.outputs.os }}-${{ hashFiles(
88+
key: cache-glfw-${{ github.workflow }}-${{ env.ImageOS }}-${{ hashFiles(
9089
'.github/scripts/Linux/install_glfw.sh' ) }}
9190
- name: bootstrap
92-
run: |
93-
. .github/scripts/environment.sh
94-
.github/scripts/Linux/prepare.sh
91+
run: .github/scripts/Linux/prepare.sh
9592

9693
- name: configure
9794
run: |

‎.github/workflows/linux.yml‎

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@ jobs:
2525
submodules: true
2626
- name: Set environment
2727
run: . .github/scripts/environment.sh
28-
- name: Identify OS version
29-
id: image
30-
run: echo "os=${ImageOS?}" >> "$GITHUB_OUTPUT"
3128
- name: Fetch SDKs ETags
3229
id: etags
3330
run: |
@@ -46,21 +43,21 @@ jobs:
4643
uses: actions/cache@main
4744
with:
4845
path: '/var/tmp/ffmpeg'
49-
key: cache-ffmpeg-${{ github.workflow }}-${{ steps.image.outputs.os }}-${{
46+
key: cache-ffmpeg-${{ github.workflow }}-${{ env.ImageOS }}-${{
5047
hashFiles( '.github/scripts/Linux/install_ffmpeg.sh',
5148
'.github/scripts/Linux/install_other.sh',
5249
'.github/scripts/Linux/ffmpeg-patches/*') }}
5350
- name: Cache SDL
5451
uses: actions/cache@main
5552
with:
5653
path: '/var/tmp/sdl'
57-
key: cache-sdl-${{ github.workflow }}-${{ steps.image.outputs.os }}-${{ hashFiles(
54+
key: cache-sdl-${{ github.workflow }}-${{ env.ImageOS }}-${{ hashFiles(
5855
'.github/scripts/Linux/install_sdl.sh' ) }}
5956
- name: Cache GLFW
6057
uses: actions/cache@main
6158
with:
6259
path: '/var/tmp/glfw'
63-
key: cache-glfw-${{ github.workflow }}-${{ steps.image.outputs.os }}-${{
60+
key: cache-glfw-${{ github.workflow }}-${{ env.ImageOS }}-${{
6461
hashFiles(
6562
'.github/scripts/Linux/install_glfw.sh',
6663
'.github/scripts/Linux/glfw-patches/*') }}

0 commit comments

Comments
 (0)