mirror of
https://github.com/jashkenas/coffeescript.git
synced 2022-11-09 12:23:24 -05:00
s/process.mainModule/require.main
This commit is contained in:
parent
09712603c4
commit
08294dc4d6
2 changed files with 2 additions and 2 deletions
|
@ -51,7 +51,7 @@
|
|||
}
|
||||
process.ARGV = process.argv = process.argv.slice(0, 2).concat(opts.literals);
|
||||
process.argv[0] = 'coffee';
|
||||
process.execPath = process.mainModule.filename;
|
||||
process.execPath = require.main.filename;
|
||||
return compileScripts();
|
||||
};
|
||||
compileScripts = function() {
|
||||
|
|
|
@ -67,7 +67,7 @@ exports.run = ->
|
|||
opts.literals = sources.splice(1).concat opts.literals
|
||||
process.ARGV = process.argv = process.argv.slice(0, 2).concat opts.literals
|
||||
process.argv[0] = 'coffee'
|
||||
process.execPath = process.mainModule.filename
|
||||
process.execPath = require.main.filename
|
||||
compileScripts()
|
||||
|
||||
# Asynchronously read in each CoffeeScript in a list of source files and
|
||||
|
|
Loading…
Reference in a new issue