File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -26,41 +26,16 @@ jobs:
2626 uses : github/codeql-action/setup-codeql@main
2727 with :
2828 tools : nightly
29- - uses : ./.github/actions/os-version
30- id : os_version
3129 # ## Build the extractor ###
32- - name : Cache entire extractor
33- id : cache-extractor
34- uses : actions/cache@v3
35- with :
36- path : |
37- ql/extractor-pack/
38- ql/target/release/buramu
39- key : ${{ runner.os }}-${{ steps.os_version.outputs.version }}-extractor-${{ hashFiles('ql/**/Cargo.lock') }}-${{ hashFiles('shared/tree-sitter-extractor') }}-${{ hashFiles('ql/**/*.rs') }}
40- - name : Cache cargo
41- if : steps.cache-extractor.outputs.cache-hit != 'true'
42- uses : actions/cache@v3
43- with :
44- path : |
45- ~/.cargo/registry
46- ~/.cargo/git
47- ql/target
48- key : ${{ runner.os }}-${{ steps.os_version.outputs.version }}-rust-cargo-${{ hashFiles('ql/**/Cargo.lock') }}
4930 - name : Release build
50- if : steps.cache-extractor.outputs.cache-hit != 'true'
5131 run : cd ql; ./scripts/create-extractor-pack.sh
5232 env :
5333 GH_TOKEN : ${{ github.token }}
54- - name : Cache compilation cache
55- id : query-cache
56- uses : ./.github/actions/cache-query-compilation
57- with :
58- key : run-ql-for-ql
5934 - name : Make database and analyze
6035 run : |
6136 ./ql/target/release/buramu | tee deprecated.blame # Add a blame file for the extractor to parse.
6237 ${CODEQL} database create --threads=0 -l=ql ${DB} --search-path "${{ github.workspace }}"
63- ${CODEQL} database analyze -j0 --format=sarif-latest --output=ql-for-ql.sarif ${DB} ql/ql/src/codeql-suites/ql-code-scanning.qls --compilation-cache "${{ steps.query-cache.outputs.cache-dir }}"
38+ ${CODEQL} database analyze -j0 --format=sarif-latest --output=ql-for-ql.sarif ${DB} ql/ql/src/codeql-suites/ql-code-scanning.qls
6439 env :
6540 CODEQL : ${{ steps.find-codeql.outputs.codeql-path }}
6641 DB : ${{ runner.temp }}/DB
Original file line number Diff line number Diff line change 2424 - name : Find codeql
2525 id : find-codeql
2626 uses : github/codeql-action/setup-codeql@main
27- - uses : ./.github/actions/os-version
28- id : os_version
29- - uses : actions/cache@v3
30- with :
31- path : |
32- ~/.cargo/registry
33- ~/.cargo/git
34- ql/target
35- key : ${{ runner.os }}-${{ steps.os_version.outputs.version }}-qltest-cargo-${{ hashFiles('ql/**/Cargo.lock') }}
3627 - name : Build Extractor
3728 run : cd ql; env "PATH=$PATH:`dirname ${CODEQL}`" ./scripts/create-extractor-pack.sh
3829 env :
Original file line number Diff line number Diff line change @@ -21,30 +21,16 @@ jobs:
2121 uses : github/codeql-action/setup-codeql@main
2222 with :
2323 tools : nightly
24- - uses : ./.github/actions/os-version
25- id : os_version
26- - uses : actions/cache@v3
27- with :
28- path : |
29- ~/.cargo/registry
30- ~/.cargo/git
31- ql/target
32- key : ${{ runner.os }}-${{ steps.os_version.outputs.version }}-qltest-cargo-${{ hashFiles('ql/rust-toolchain.toml', 'ql/**/Cargo.lock') }}
3324 - name : Check formatting
3425 run : cd ql; cargo fmt -- --check
3526 - name : Build extractor
3627 run : |
3728 cd ql;
3829 codeqlpath=$(dirname ${{ steps.find-codeql.outputs.codeql-path }});
3930 env "PATH=$PATH:$codeqlpath" ./scripts/create-extractor-pack.sh
40- - name : Cache compilation cache
41- id : query-cache
42- uses : ./.github/actions/cache-query-compilation
43- with :
44- key : ql-for-ql-tests
4531 - name : Run QL tests
4632 run : |
47- "${CODEQL}" test run --threads=0 --check-databases --check-unused-labels --check-repeated-labels --check-redefined-labels --check-use-before-definition --search-path "${{ github.workspace }}" --consistency-queries ql/ql/consistency-queries --compilation-cache "${{ steps.query-cache.outputs.cache-dir }}" ql/ql/test
33+ "${CODEQL}" test run --threads=0 --check-databases --check-unused-labels --check-repeated-labels --check-redefined-labels --check-use-before-definition --search-path "${{ github.workspace }}" --consistency-queries ql/ql/consistency-queries ql/ql/test
4834 env :
4935 CODEQL : ${{ steps.find-codeql.outputs.codeql-path }}
5036
6652 uses : github/codeql-action/setup-codeql@main
6753 with :
6854 tools : nightly
69- - uses : ./.github/actions/os-version
70- id : os_version
71- - uses : actions/cache@v3
72- with :
73- path : |
74- ~/.cargo/registry
75- ~/.cargo/git
76- ql/target
77- key : ${{ runner.os }}-${{ steps.os_version.outputs.version }}-qltest-cargo-${{ hashFiles('ql/rust-toolchain.toml', 'ql/**/Cargo.lock') }}
7855 - name : Build extractor
7956 if : runner.os != 'Windows'
8057 run : |
You can’t perform that action at this time.
0 commit comments