Skip to content

Commit 1752638

Browse files
committed
Fixes #976 running with java 8 nashorn produces ReferenceError: process is not defined
1 parent c0f2086 commit 1752638

File tree

4 files changed

+13
-13
lines changed

4 files changed

+13
-13
lines changed

build/jslib/uglifyjs.js

-5
Original file line numberDiff line numberDiff line change
@@ -10416,11 +10416,6 @@ exports["is_identifier"] = is_identifier;
1041610416
exports["SymbolDef"] = SymbolDef;
1041710417

1041810418
AST_Node.warn_function = function(txt) { logger.error("uglifyjs WARN: " + txt); };
10419-
// workaround for tty output truncation upon process.exit()
10420-
[process.stdout, process.stderr].forEach(function(stream){
10421-
if (stream._handle && stream._handle.setBlocking)
10422-
stream._handle.setBlocking(true);
10423-
});
1042410419

1042510420
exports.AST_Node.warn_function = function(txt) {
1042610421
console.error("WARN: %s", txt);

build/jslib/uglifyjs/README.md

+10
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,16 @@ THINGS TO CHECK:
2323

2424
REMOVE this section:
2525

26+
```javascript
27+
// workaround for tty output truncation upon process.exit()
28+
[process.stdout, process.stderr].forEach(function(stream){
29+
if (stream._handle && stream._handle.setBlocking)
30+
stream._handle.setBlocking(true);
31+
});
32+
```
33+
34+
ALSO REMOVE this section:
35+
2636
```javascript
2737
var path = require("path");
2838
var fs = require("fs");

build/jslib/x.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ var requirejs, require, define, xpcUtil;
1919
(function (console, args, readFileFunc) {
2020
var fileName, env, fs, vm, path, exec, rhinoContext, dir, nodeRequire,
2121
nodeDefine, exists, reqMain, loadedOptimizedLib, existsForNode, Cc, Ci,
22-
version = '2.3.5',
22+
version = '2.3.5+',
2323
jsSuffixRegExp = /\.js$/,
2424
commandOption = '',
2525
useLibLoaded = {},

dist/r.js

+2-7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @license r.js 2.3.5 Copyright jQuery Foundation and other contributors.
2+
* @license r.js 2.3.5 Mon, 12 Feb 2018 00:23:55 GMT Copyright jQuery Foundation and other contributors.
33
* Released under MIT license, http://github.com/requirejs/r.js/LICENSE
44
*/
55

@@ -19,7 +19,7 @@ var requirejs, require, define, xpcUtil;
1919
(function (console, args, readFileFunc) {
2020
var fileName, env, fs, vm, path, exec, rhinoContext, dir, nodeRequire,
2121
nodeDefine, exists, reqMain, loadedOptimizedLib, existsForNode, Cc, Ci,
22-
version = '2.3.5',
22+
version = '2.3.5+ Mon, 12 Feb 2018 00:23:55 GMT',
2323
jsSuffixRegExp = /\.js$/,
2424
commandOption = '',
2525
useLibLoaded = {},
@@ -24656,11 +24656,6 @@ exports["is_identifier"] = is_identifier;
2465624656
exports["SymbolDef"] = SymbolDef;
2465724657

2465824658
AST_Node.warn_function = function(txt) { logger.error("uglifyjs WARN: " + txt); };
24659-
// workaround for tty output truncation upon process.exit()
24660-
[process.stdout, process.stderr].forEach(function(stream){
24661-
if (stream._handle && stream._handle.setBlocking)
24662-
stream._handle.setBlocking(true);
24663-
});
2466424659

2466524660
exports.AST_Node.warn_function = function(txt) {
2466624661
console.error("WARN: %s", txt);

0 commit comments

Comments
 (0)