forked from microsoft/vscode-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpythonVersion.ts
More file actions
27 lines (26 loc) · 928 Bytes
/
pythonVersion.ts
File metadata and controls
27 lines (26 loc) · 928 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
/**
* A representation of a Python runtime's version.
*
* @prop raw - the original version string
* @prop major - the "major" version
* @prop minor - the "minor" version
* @prop patch - the "patch" (or "micro") version
* @prop build - the build ID of the executable
* @prop prerelease - identifies a tag in the release process (e.g. beta 1)
*/
// Note that this is currently compatible with SemVer objects,
// but we may change it to match the format of sys.version_info.
export type PythonVersion = {
raw: string;
major: number;
minor: number;
patch: number;
// Eventually it may be useful to match what sys.version_info
// provides for the remainder here:
// * releaseLevel: 'alpha' | 'beta' | 'candidate' | 'final';
// * serial: number;
build: string[];
prerelease: string[];
};