Merge pull request #2245 from billti/ExportVersion

Made the 'version' string an exported property
This commit is contained in:
Bill Ticehurst
2015-03-07 21:40:32 -08:00
11 changed files with 38 additions and 4 deletions
+3
View File
@@ -5,6 +5,9 @@ module ts {
/* @internal */ export var emitTime = 0;
/* @internal */ export var ioReadTime = 0;
/** The version of the TypeScript compiler release */
export var version = "1.5.0.0";
export function createCompilerHost(options: CompilerOptions): CompilerHost {
var currentDirectory: string;
var existingDirectories: Map<boolean> = {};
+2 -4
View File
@@ -2,8 +2,6 @@
/// <reference path="commandLineParser.ts"/>
module ts {
var version = "1.5.0.0";
export interface SourceFile {
fileWatcher: FileWatcher;
}
@@ -178,7 +176,7 @@ module ts {
}
if (commandLine.options.version) {
reportDiagnostic(createCompilerDiagnostic(Diagnostics.Version_0, version));
reportDiagnostic(createCompilerDiagnostic(Diagnostics.Version_0, ts.version));
return sys.exit(ExitStatus.Success);
}
@@ -419,7 +417,7 @@ module ts {
}
function printVersion() {
sys.write(getDiagnosticText(Diagnostics.Version_0, version) + sys.newLine);
sys.write(getDiagnosticText(Diagnostics.Version_0, ts.version) + sys.newLine);
}
function printHelp() {
+1
View File
@@ -11,6 +11,7 @@
/// <reference path='formatting\smartIndenter.ts' />
module ts {
/** The version of the language service API */
export var servicesVersion = "0.4"
export interface Node {