Skip to content

Commit 1856e2b

Browse files
committed
fixup the $schema in all .sarif files
1 parent 6e2f3e2 commit 1856e2b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.github/workflows/ql-for-ql-build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,9 @@ jobs:
192192
category: "ql-for-ql-${{ matrix.folder }}"
193193
- name: Copy sarif file to CWD
194194
run: cp ../results/ql.sarif ./${{ matrix.folder }}.sarif
195+
- name: Fixup the $scema in sarif # Until https://github.com/microsoft/sarif-vscode-extension/pull/436/ is part in a stable release
196+
run: |
197+
sed -i 's/\$schema.*/\$schema": "https:\/\/raw.githubusercontent.com\/oasis-tcs\/sarif-spec\/master\/Schemata\/sarif-schema-2.1.0",/' ${{ matrix.folder }}.sarif
195198
- name: Sarif as artifact
196199
uses: actions/upload-artifact@v3
197200
with:

ql/scripts/merge-sarif.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,6 @@ async function main(files) {
1818
out.runs[0].artifacts = []; // the indexes in these won't make sense, so I hope this works.
1919
out.runs[0].results = combinedResults;
2020

21-
// workaround until https://github.com/microsoft/sarif-vscode-extension/pull/436/ is part of a release
22-
out["$schema"] = "https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0";
23-
2421
fs.writeFileSync(outFile, JSON.stringify(out, null, 2));
2522
}
2623
main(process.argv.splice(2));

0 commit comments

Comments
 (0)