mirror of
https://github.com/microsoft/pyright.git
synced 2024-10-26 19:01:08 +03:00
Small tweaks to version printing code.
This commit is contained in:
parent
c3ca99be3f
commit
2f148e88a7
@ -10,7 +10,7 @@ Pyright can be run as either a VS Code extension or as a node-based command-line
|
||||
| -t, --typeshed-path DIRECTORY | Use typeshed type stubs at this location (1) |
|
||||
| -v, --venv-path DIRECTORY | Directory that contains virtual environments (2) |
|
||||
| --verbose | Emit verbose diagnostics |
|
||||
| --version | Print Pyright version |
|
||||
| --version | Print pyright version |
|
||||
| -w, --watch | Continue to run and watch for changes (3) |
|
||||
|
||||
|
||||
|
@ -67,7 +67,8 @@ function processArgs() {
|
||||
printVersion();
|
||||
return;
|
||||
}
|
||||
let options = new PyrightCommandLineOptions(process.cwd(), false);
|
||||
|
||||
const options = new PyrightCommandLineOptions(process.cwd(), false);
|
||||
|
||||
// Assume any relative paths are relative to the working directory.
|
||||
if (args.files && Array.isArray(args.files)) {
|
||||
@ -149,7 +150,8 @@ function printUsage() {
|
||||
}
|
||||
|
||||
function printVersion() {
|
||||
console.log( 'Pyright ' + String(require('package.json').version));
|
||||
const version = require('package.json').version;
|
||||
console.log(`${ toolName } ${ version.toString() }`);
|
||||
}
|
||||
|
||||
function reportDiagnostics(fileDiagnostics: FileDiagnostics[]): number {
|
||||
|
Loading…
Reference in New Issue
Block a user