Skip to content

Commit

Permalink
Add cli version for message
Browse files Browse the repository at this point in the history
  • Loading branch information
aeisenberg committed Apr 9, 2021
1 parent 35ad10b commit ddaa983
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
6 changes: 3 additions & 3 deletions extensions/ql-vscode/src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ export class CodeQLCliServer implements Disposable {
/**
* CLI version where the `codeql resolve qlref` command is available.
*/
private static CLI_VERSION_WITH_RESOLVE_QLREF = new SemVer('2.5.1');
public static CLI_VERSION_WITH_RESOLVE_QLREF = new SemVer('2.5.1');

/** The process for the cli server, or undefined if one doesn't exist yet */
process?: child_process.ChildProcessWithoutNullStreams;
Expand Down Expand Up @@ -937,11 +937,11 @@ class SplitBuffer {

/**
* A version of startsWith that isn't overriden by a broken version of ms-python.
*
*
* The definition comes from
* https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/startsWith
* which is CC0/public domain
*
*
* See https://github.com/github/vscode-codeql/issues/802 for more context as to why we need it.
*/
private static startsWith(s: string, searchString: string, position: number): boolean {
Expand Down
4 changes: 3 additions & 1 deletion extensions/ql-vscode/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,9 @@ async function activateWithInstalledDistribution(
helpers.showAndLogErrorMessage(
'Jumping from a .qlref file to the .ql file it references is not '
+ 'supported with the CLI version you are running.\n'
+ 'Please upgrade your CLI to use this feature.');
+ `Please upgrade your CLI to version ${
CodeQLCliServer.CLI_VERSION_WITH_RESOLVE_QLREF
} or later to use this feature.`);
}
}
}
Expand Down

0 comments on commit ddaa983

Please sign in to comment.