diff --git a/internal/execute/tsc.go b/internal/execute/tsc.go index 0b5203cd22..c226e5f468 100644 --- a/internal/execute/tsc.go +++ b/internal/execute/tsc.go @@ -5,6 +5,7 @@ import ( "encoding/json" "fmt" "runtime" + "strings" "time" "github.com/microsoft/typescript-go/internal/ast" @@ -19,6 +20,16 @@ import ( type cbType = func(p any) any func CommandLine(sys System, cb cbType, commandLineArgs []string) ExitStatus { + if len(commandLineArgs) > 0 { + // !!! build mode + switch strings.ToLower(commandLineArgs[0]) { + case "-b", "--b", "-build", "--build": + fmt.Fprint(sys.Writer(), "Build mode is currently unsupported."+sys.NewLine()) + sys.EndWrite() + return ExitStatusNotImplemented + } + } + parsedCommandLine := tsoptions.ParseCommandLine(commandLineArgs, sys) e, watcher := executeCommandLineWorker(sys, cb, parsedCommandLine) if watcher == nil {