From 8bf8adfc7432d38fea71df2e8466aed9292c6880 Mon Sep 17 00:00:00 2001 From: Elena Tanasoiu Date: Tue, 21 Feb 2023 19:04:54 +0000 Subject: [PATCH] Fix default query for skeleton pack We mark this query as `@kind problem`. We'll need to change the query a bit to make it fit this type of ... erm... kind. This means the results view will be formatted to display the file name next to each of the results. We're also getting rid of any mentions of an empty block query since that's no longer what it checks. --- extensions/ql-vscode/src/qlpack-generator.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/extensions/ql-vscode/src/qlpack-generator.ts b/extensions/ql-vscode/src/qlpack-generator.ts index 023984720..16809d708 100644 --- a/extensions/ql-vscode/src/qlpack-generator.ts +++ b/extensions/ql-vscode/src/qlpack-generator.ts @@ -72,15 +72,16 @@ export class QlPackGenerator { const exampleQl = ` /** * This is an automatically generated file - * @name Empty block + * @name Hello world * @kind problem * @problem.severity warning - * @id ${this.queryLanguage}/example/empty-block + * @id ${this.queryLanguage}/example/hello-world */ import ${this.queryLanguage} -select "Hello, world!" +from File f +select f, "Hello, world!" `.trim(); await writeFile(exampleQlFilePath, exampleQl, "utf8");