Skip to content

Commit f7bd70c

Browse files
authored
Merge branch 'main' into henrymercer/failed-upload-logs
2 parents 5848d11 + 4ff91f1 commit f7bd70c

File tree

5 files changed

+58
-8
lines changed

5 files changed

+58
-8
lines changed

.github/workflows/__autobuild-direct-tracing-with-working-dir.yml

Lines changed: 17 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/workflows/__autobuild-direct-tracing.yml

Lines changed: 17 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pr-checks/checks/autobuild-direct-tracing-with-working-dir.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ description: >
55
autobuild Action.
66
operatingSystems: ["ubuntu", "windows"]
77
versions: ["linked", "nightly-latest"]
8+
installJava: "true"
89
env:
910
CODEQL_ACTION_AUTOBUILD_BUILD_MODE_DIRECT_TRACING: true
1011
steps:

pr-checks/checks/autobuild-direct-tracing.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: "Autobuild direct tracing"
22
description: "An end-to-end integration test of a Java repository built using 'build-mode: autobuild', with direct tracing enabled"
33
operatingSystems: ["ubuntu", "windows"]
44
versions: ["linked", "nightly-latest"]
5+
installJava: "true"
56
env:
67
CODEQL_ACTION_AUTOBUILD_BUILD_MODE_DIRECT_TRACING: true
78
steps:
@@ -19,7 +20,7 @@ steps:
1920
db-location: "${{ runner.temp }}/customDbLocation"
2021
languages: java
2122
tools: ${{ steps.prepare-test.outputs.tools-url }}
22-
23+
2324
- name: Check that indirect tracing is disabled
2425
shell: bash
2526
run: |

pr-checks/sync.py

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,7 @@ def writeHeader(checkStream):
114114
},
115115
]
116116

117-
installGo = False
118-
if checkSpecification.get('installGo'):
119-
installGo = True if checkSpecification['installGo'].lower() == "true" else False
117+
installGo = checkSpecification.get('installGo', '').lower() == 'true'
120118

121119
if installGo:
122120
baseGoVersionExpr = '>=1.21.0'
@@ -138,6 +136,26 @@ def writeHeader(checkStream):
138136
}
139137
})
140138

139+
installJava = checkSpecification.get('installJava', '').lower() == 'true'
140+
141+
if installJava:
142+
baseJavaVersionExpr = '17'
143+
workflowInputs['java-version'] = {
144+
'type': 'string',
145+
'description': 'The version of Java to install',
146+
'required': False,
147+
'default': baseJavaVersionExpr,
148+
}
149+
150+
steps.append({
151+
'name': 'Install Java',
152+
'uses': 'actions/setup-java@v4',
153+
'with': {
154+
'java-version': '${{ inputs.java-version || \'' + baseJavaVersionExpr + '\' }}',
155+
'distribution': 'temurin'
156+
}
157+
})
158+
141159
# If container initialisation steps are present in the check specification,
142160
# make sure to execute them first.
143161
if 'container' in checkSpecification and 'container-init-steps' in checkSpecification:

0 commit comments

Comments
 (0)