mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-05-03 03:00:14 -04:00
Turning --compile on when --output is set, because it's probably what was intended.
This commit is contained in:
@@ -192,6 +192,7 @@
|
||||
var o;
|
||||
optionParser = new optparse.OptionParser(SWITCHES, BANNER);
|
||||
o = (options = optionParser.parse(process.argv.slice(2, process.argv.length)));
|
||||
options.compile = options.compile || !!o.output;
|
||||
options.run = !(o.compile || o.print || o.lint);
|
||||
options.print = !!(o.print || (o.eval || o.stdio && o.compile));
|
||||
sources = options.arguments;
|
||||
|
||||
@@ -154,11 +154,12 @@ printTokens: (tokens) ->
|
||||
# Use the [OptionParser module](optparse.html) to extract all options from
|
||||
# `process.argv` that are specified in `SWITCHES`.
|
||||
parseOptions: ->
|
||||
optionParser: new optparse.OptionParser SWITCHES, BANNER
|
||||
o: options: optionParser.parse(process.argv[2...process.argv.length])
|
||||
options.run: not (o.compile or o.print or o.lint)
|
||||
options.print: !! (o.print or (o.eval or o.stdio and o.compile))
|
||||
sources: options.arguments
|
||||
optionParser: new optparse.OptionParser SWITCHES, BANNER
|
||||
o: options: optionParser.parse(process.argv[2...process.argv.length])
|
||||
options.compile: or !!o.output
|
||||
options.run: not (o.compile or o.print or o.lint)
|
||||
options.print: !! (o.print or (o.eval or o.stdio and o.compile))
|
||||
sources: options.arguments
|
||||
|
||||
# The compile-time options to pass to the CoffeeScript compiler.
|
||||
compileOptions: (source) ->
|
||||
|
||||
Reference in New Issue
Block a user