File tree Expand file tree Collapse file tree 3 files changed +9
-29
lines changed Expand file tree Collapse file tree 3 files changed +9
-29
lines changed Original file line number Diff line number Diff line change @@ -28706,14 +28706,9 @@ async function codeqlDatabaseAnalyze(codeql, database_path) {
28706
28706
"--output",
28707
28707
codeql_output,
28708
28708
];
28709
- const extPackPath = process.env["EXTPACK_PATH"];
28710
- const extPackName = process.env["EXTPACK_NAME"];
28711
- if (extPackPath !== undefined &&
28712
- extPackName !== undefined &&
28713
- extPackPath !== "" &&
28714
- extPackName !== "") {
28715
- cmd.push("--additional-packs", extPackPath);
28716
- cmd.push("--extension-packs", extPackName);
28709
+ const useWorkflowModels = process.env["USE_WORKFLOW_MODELS"];
28710
+ if (useWorkflowModels !== undefined && useWorkflowModels == "true") {
28711
+ cmd.push("--extension-packs", "local/workflow-models");
28717
28712
}
28718
28713
// remote pack or local pack
28719
28714
if (codeql.pack.startsWith("githubsecuritylab/")) {
Original file line number Diff line number Diff line change @@ -147,16 +147,9 @@ export async function codeqlDatabaseAnalyze(
147
147
codeql_output ,
148
148
] ;
149
149
150
- const extPackPath = process . env [ "EXTPACK_PATH" ] ;
151
- const extPackName = process . env [ "EXTPACK_NAME" ] ;
152
- if (
153
- extPackPath !== undefined &&
154
- extPackName !== undefined &&
155
- extPackPath !== "" &&
156
- extPackName !== ""
157
- ) {
158
- cmd . push ( "--additional-packs" , extPackPath ) ;
159
- cmd . push ( "--extension-packs" , extPackName ) ;
150
+ const useWorkflowModels = process . env [ "USE_WORKFLOW_MODELS" ] ;
151
+ if ( useWorkflowModels !== undefined && useWorkflowModels == "true" ) {
152
+ cmd . push ( "--extension-packs" , "local/workflow-models" ) ;
160
153
}
161
154
162
155
// remote pack or local pack
Original file line number Diff line number Diff line change @@ -14,27 +14,21 @@ inputs:
14
14
suite :
15
15
description : " CodeQL Suite to run"
16
16
default : " actions-code-scanning"
17
- workflow-extpack-path :
18
- description : " Path to Workflow extpack"
19
- required : false
20
- workflow-extpack-name :
21
- description : " Name of the Workflow extpack"
22
- required : false
23
17
24
18
runs :
25
19
using : ' composite'
26
20
steps :
27
21
- name : extpack contents
28
22
shell : bash
29
23
env :
30
- EXTPACK_PATH : ${{ inputs. workflow-extpack-path }}
31
- EXTPACK_NAME : ${{ inputs. workflow-extpack-name }}
24
+ EXTPACK_PATH : /home/runner/.codeql/packages/local/ workflow-models/0.0.1
25
+ EXTPACK_NAME : local/ workflow-models
32
26
run : |
33
27
echo "##[group] Workflow Models"
34
28
if [ -f $EXTPACK_PATH/models.yml ]; then cat $EXTPACK_PATH/models.yml; fi
35
29
echo "##[endgroup]"
36
30
echo "##[group] QLPack"
37
- if [ -f $EXTPACK_PATH/qlpack .yml ]; then cat $EXTPACK_PATH/qlpack .yml; fi
31
+ if [ -f $EXTPACK_PATH/codeql-pack .yml ]; then cat $EXTPACK_PATH/codeql-pack .yml; echo "USE_WORKFLOW_MODELS=true" >> $GITHUB_ENV ; fi
38
32
echo "##[endgroup]"
39
33
40
34
- name : Scan workflows
45
39
INPUT_SOURCE-ROOT : ${{ inputs.source-root }}
46
40
INPUT_SARIF-OUTPUT : ${{ inputs.sarif-output }}
47
41
INPUT_SUITE : ${{ inputs.suite }}
48
- EXTPACK_PATH : ${{ inputs.workflow-extpack-path }}
49
- EXTPACK_NAME : ${{ inputs.workflow-extpack-name }}
50
42
run : |
51
43
node ${{ github.action_path }}/.github/action/dist/index.js
You can’t perform that action at this time.
0 commit comments