mirror of
https://github.com/ast-grep/ast-grep.git
synced 2026-05-06 06:06:46 -04:00
d4204a0579
fix #141
25 lines
604 B
Plaintext
25 lines
604 B
Plaintext
import * as ts from "./_namespaces/ts";
|
|
|
|
// This file actually uses arguments passed on commandline and executes it
|
|
|
|
// enable deprecation logging
|
|
ts.Debug.loggingHost = {
|
|
log(_level, s) {
|
|
ts.sys.write(`${s || ""}${ts.sys.newLine}`);
|
|
}
|
|
};
|
|
|
|
if (ts.Debug.isDebugging) {
|
|
ts.Debug.enableDebugInfo();
|
|
}
|
|
|
|
if (ts.sys.tryEnableSourceMapsForHost && /^development$/i.test(ts.sys.getEnvironmentVariable("NODE_ENV"))) {
|
|
ts.sys.tryEnableSourceMapsForHost();
|
|
}
|
|
|
|
if (ts.sys.setBlocking) {
|
|
ts.sys.setBlocking();
|
|
}
|
|
|
|
ts.executeCommandLine(ts.sys, ts.noop, ts.sys.args);
|