diff --git a/extensions/ql-vscode/gulpfile.ts/textmate.ts b/extensions/ql-vscode/gulpfile.ts/textmate.ts index 0b7d2b88fac..8e061b440f9 100644 --- a/extensions/ql-vscode/gulpfile.ts/textmate.ts +++ b/extensions/ql-vscode/gulpfile.ts/textmate.ts @@ -9,6 +9,7 @@ import type { Pattern, TextmateGrammar, } from "./textmate-grammar"; +import { pipeline } from "stream/promises"; /** * Replaces all rule references with the match pattern of the referenced rule. @@ -276,7 +277,9 @@ export function transpileTextMateGrammar() { } export function compileTextMateGrammar() { - return src("syntaxes/*.tmLanguage.yml") - .pipe(transpileTextMateGrammar()) - .pipe(dest("out/syntaxes")); + return pipeline( + src("syntaxes/*.tmLanguage.yml"), + transpileTextMateGrammar(), + dest("out/syntaxes"), + ); } diff --git a/extensions/ql-vscode/gulpfile.ts/typescript.ts b/extensions/ql-vscode/gulpfile.ts/typescript.ts index c7f12785507..abd3591b096 100644 --- a/extensions/ql-vscode/gulpfile.ts/typescript.ts +++ b/extensions/ql-vscode/gulpfile.ts/typescript.ts @@ -4,6 +4,7 @@ import esbuild from "gulp-esbuild"; import type { reporter } from "gulp-typescript"; import { createProject } from "gulp-typescript"; import del from "del"; +import { pipeline } from "stream/promises"; export function goodReporter(): reporter.Reporter { return { @@ -37,23 +38,23 @@ export function cleanOutput() { } export function compileEsbuild() { - return src("./src/extension.ts") - .pipe( - esbuild({ - outfile: "extension.js", - bundle: true, - external: ["vscode", "fsevents"], - format: "cjs", - platform: "node", - target: "es2020", - sourcemap: "linked", - sourceRoot: "..", - loader: { - ".node": "copy", - }, - }), - ) - .pipe(dest("out")); + return pipeline( + src("./src/extension.ts"), + esbuild({ + outfile: "extension.js", + bundle: true, + external: ["vscode", "fsevents"], + format: "cjs", + platform: "node", + target: "es2020", + sourcemap: "linked", + sourceRoot: "..", + loader: { + ".node": "copy", + }, + }), + dest("out"), + ); } export function watchEsbuild() { diff --git a/extensions/ql-vscode/gulpfile.ts/view.ts b/extensions/ql-vscode/gulpfile.ts/view.ts index fea09031d70..698f39c113e 100644 --- a/extensions/ql-vscode/gulpfile.ts/view.ts +++ b/extensions/ql-vscode/gulpfile.ts/view.ts @@ -3,28 +3,29 @@ import esbuild from "gulp-esbuild"; import { createProject } from "gulp-typescript"; import { goodReporter } from "./typescript"; +import { pipeline } from "stream/promises"; import chromiumVersion from "./chromium-version.json"; const tsProject = createProject("src/view/tsconfig.json"); export function compileViewEsbuild() { - return src("./src/view/webview.tsx") - .pipe( - esbuild({ - outfile: "webview.js", - bundle: true, - format: "iife", - platform: "browser", - target: `chrome${chromiumVersion.chromiumVersion}`, - jsx: "automatic", - sourcemap: "linked", - sourceRoot: "..", - loader: { - ".ttf": "file", - }, - }), - ) - .pipe(dest("out")); + return pipeline( + src("./src/view/webview.tsx"), + esbuild({ + outfile: "webview.js", + bundle: true, + format: "iife", + platform: "browser", + target: `chrome${chromiumVersion.chromiumVersion}`, + jsx: "automatic", + sourcemap: "linked", + sourceRoot: "..", + loader: { + ".ttf": "file", + }, + }), + dest("out"), + ); } export function watchViewEsbuild() {