Skip to content

Commit 97fd9c0

Browse files
authored
Merge pull request #20 from purescript-node/compiler/0.12
Compiler/0.12
2 parents 5c09f73 + 3271efc commit 97fd9c0

File tree

6 files changed

+264
-116
lines changed

6 files changed

+264
-116
lines changed

.travis.yml

+7-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
11
language: node_js
22
dist: trusty
33
sudo: required
4-
node_js: 6
4+
node_js: stable
5+
env:
6+
- PATH=$HOME/purescript:$PATH
57
install:
8+
- TAG=$(wget -q -O - https://github.com/purescript/purescript/releases/latest --server-response --max-redirect 0 2>&1 | sed -n -e 's/.*Location:.*tag\///p')
9+
- wget -O $HOME/purescript.tar.gz https://github.com/purescript/purescript/releases/download/$TAG/linux64.tar.gz
10+
- tar -xvf $HOME/purescript.tar.gz -C $HOME/
11+
- chmod a+x $HOME/purescript
612
- npm install -g bower
713
- npm install
814
script:

bower.json

+10-10
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,17 @@
1616
"package.json"
1717
],
1818
"dependencies": {
19-
"purescript-exceptions": "^3.0.0",
20-
"purescript-foreign": "^4.0.0",
21-
"purescript-functions": "^3.0.0",
22-
"purescript-maps": "^3.0.0",
23-
"purescript-node-fs": "^4.0.0",
24-
"purescript-node-streams": "^3.0.0",
25-
"purescript-nullable": "^3.0.0",
26-
"purescript-posix-types": "^3.0.0",
27-
"purescript-unsafe-coerce": "^3.0.0"
19+
"purescript-exceptions": "^4.0.0",
20+
"purescript-foreign": "^5.0.0",
21+
"purescript-functions": "^4.0.0",
22+
"purescript-node-fs": "^5.0.0",
23+
"purescript-node-streams": "^4.0.0",
24+
"purescript-nullable": "^4.0.0",
25+
"purescript-posix-types": "^4.0.0",
26+
"purescript-unsafe-coerce": "^4.0.0",
27+
"purescript-foreign-object": "^1.0.0"
2828
},
2929
"devDependencies": {
30-
"purescript-console": "^3.0.0"
30+
"purescript-console": "^4.1.0"
3131
}
3232
}

package.json

+4-5
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,9 @@
55
"build": "eslint src && pulp build -- --censor-lib --strict"
66
},
77
"devDependencies": {
8-
"eslint": "^3.17.1",
9-
"pulp": "^11.0.0",
10-
"purescript-psa": "^0.5.0",
11-
"purescript": "^0.11.1",
12-
"rimraf": "^2.5.4"
8+
"eslint": "^4.19.1",
9+
"pulp": "^12.2.0",
10+
"purescript-psa": "^0.6.0",
11+
"rimraf": "^2.6.2"
1312
}
1413
}

src/Node/ChildProcess.js

+20-1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ exports.execImpl = function execImpl (command) {
3131
};
3232
};
3333

34+
3435
exports.execFileImpl = function execImpl (command) {
3536
return function (args) {
3637
return function (opts) {
@@ -45,6 +46,24 @@ exports.execFileImpl = function execImpl (command) {
4546
};
4647
};
4748

49+
exports.execSyncImpl = function execSyncImpl (command) {
50+
return function (opts) {
51+
return function () {
52+
return require('child_process').execSync(command, opts);
53+
};
54+
};
55+
};
56+
57+
exports.execFileSyncImpl = function execFileSyncImpl (command) {
58+
return function (args) {
59+
return function (opts) {
60+
return function () {
61+
return require('child_process').execFileSync(command, args, opts);
62+
};
63+
};
64+
};
65+
};
66+
4867
exports.fork = function fork (cmd) {
4968
return function (args) {
5069
return function () {
@@ -69,7 +88,7 @@ exports.mkOnClose = function mkOnClose (mkChildExit) {
6988
return function onClose (cp) {
7089
return function (cb) {
7190
return function () {
72-
cp.on('exit', function (code, signal) {
91+
cp.on('close', function (code, signal) {
7392
cb(mkChildExit(code)(signal))();
7493
});
7594
};

0 commit comments

Comments
 (0)