28
28
with :
29
29
python-version : " 3.9"
30
30
31
+ - name : Install CodeQL
32
+ run : |
33
+ VERSION="v$( jq -r '.supported_environment | .[0] | .codeql_cli' supported_codeql_configs.json)"
34
+ gh extensions install github/gh-codeql
35
+ gh codeql set-version "$VERSION"
36
+ gh codeql install-stub
37
+ env :
38
+ GITHUB_TOKEN : ${{ github.token }}
39
+
31
40
- name : Install generate_package_files.py dependencies
32
41
run : pip install -r scripts/requirements.txt
33
42
@@ -49,14 +58,14 @@ jobs:
49
58
50
59
- name : Validate Package Files (CPP)
51
60
run : |
52
- find rule_packages/cpp -name \*.json -exec basename {} .json \; | xargs --max-procs "$XARGS_MAX_PROCS" --max-args 1 python scripts/generate_rules/generate_package_files.py cpp
61
+ find rule_packages/cpp -name \*.json -exec basename {} .json \; | xargs python scripts/generate_rules/generate_package_files.py cpp
53
62
git diff
54
63
git diff --compact-summary
55
64
git diff --quiet
56
65
57
66
- name : Validate Package Files (C)
58
67
run : |
59
- find rule_packages/c -name \*.json -exec basename {} .json \; | xargs --max-procs "$XARGS_MAX_PROCS" --max-args 1 python scripts/generate_rules/generate_package_files.py c
68
+ find rule_packages/c -name \*.json -exec basename {} .json \; | xargs python scripts/generate_rules/generate_package_files.py c
60
69
git diff
61
70
git diff --compact-summary
62
71
git diff --quiet
@@ -68,25 +77,26 @@ jobs:
68
77
- name : Checkout
69
78
uses : actions/checkout@v2
70
79
71
- - name : Fetch CodeQL
80
+ - name : Install CodeQL
72
81
run : |
73
- TAG="v$( jq -r '.supported_environment | .[0] | .codeql_cli' supported_codeql_configs.json)"
74
- gh release download $TAG --repo https://github.com/github/codeql-cli-binaries --pattern codeql-linux64.zip
75
- unzip -q codeql-linux64.zip
82
+ VERSION="v$( jq -r '.supported_environment | .[0] | .codeql_cli' supported_codeql_configs.json)"
83
+ gh extensions install github/gh-codeql
84
+ gh codeql set-version "$VERSION"
85
+ gh codeql install-stub
76
86
env :
77
87
GITHUB_TOKEN : ${{ github.token }}
78
88
79
89
- name : Validate CodeQL Format (CPP)
80
90
run : |
81
- find cpp -name \*.ql -or -name \*.qll -print0 | xargs -0 --max-procs "$XARGS_MAX_PROCS" codeql/codeql query format --in-place
91
+ find cpp -name \*.ql -or -name \*.qll -print0 | xargs -0 --max-procs "$XARGS_MAX_PROCS" codeql query format --in-place
82
92
83
93
git diff
84
94
git diff --compact-summary
85
95
git diff --quiet
86
96
87
97
- name : Validate CodeQL Format (C)
88
98
run : |
89
- find c -name \*.ql -or -name \*.qll -print0 | xargs -0 --max-procs "$XARGS_MAX_PROCS" codeql/codeql query format --in-place
99
+ find c -name \*.ql -or -name \*.qll -print0 | xargs -0 --max-procs "$XARGS_MAX_PROCS" codeql query format --in-place
90
100
91
101
git diff
92
102
git diff --compact-summary
0 commit comments