Skip to content

Commit 7bcafe4

Browse files
committed
Release v0.9.2
1 parent 64f3b2e commit 7bcafe4

File tree

4 files changed

+19
-17
lines changed

4 files changed

+19
-17
lines changed

hapi-server

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ if type $path"/bin/node" &> /dev/null; then
88
elif type node &> /dev/null; then
99
node $path"/server.js" $@
1010
elif type nodejs &> /dev/null; then
11-
node $path"/server.js" $@
11+
nodejs $path"/server.js" $@
1212
else
1313
echo "Did not find "$(dirname "$SCRIPT")"/bin/node, node, or nodejs"
1414
fi

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "hapi-server",
3-
"version": "0.9.1",
3+
"version": "0.9.2",
44
"license": "MIT",
55
"engine-strict": true,
66
"engines": {
@@ -29,7 +29,7 @@
2929
"clean": "rm -rf node_modules/; rm -rf public/data/QinDenton/",
3030
"test": "node test/test.js",
3131
"start": "node server.js --port 8999",
32-
"release": "rm -rf node_modules; npm install --production; source pkg/GITHUB_TOKEN && release-it $npm_package_version --preRelease=beta --no-git.requireCleanWorkingDir"
32+
"release": "cd pkg; make release VERSION=v$npm_package_version"
3333
},
3434
"bin": "server.js",
3535
"release-it": {

pkg/Makefile

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ DIST=darwin-x64
77
#DIST=linux-armv7l # Did this on Pi 3+
88
#DIST=win-x64
99

10+
release:
11+
cd ..; rm -rf node_modules; npm install --production;
12+
make update VERSION=$(VERSION);
13+
cd ..; source pkg/GITHUB_TOKEN && release-it $(VERSION) --preRelease=beta --no-git.requireCleanWorkingDir --no-npm.publish
14+
1015
# When node and python binaries do not need to be updated.
1116
update:
1217
make package OS=darwin-x64
@@ -81,14 +86,12 @@ files:
8186
--exclude pkg \
8287
--exclude .git \
8388
--exclude public/data/QinDenton \
84-
../ dist/hapi-server-$(VERSION)/
85-
cd dist/hapi-server-$(VERSION); \
86-
rm -f *.md \
87-
rm -f package* \
88-
rm -rf .git* \
89-
rm -rf node_modules/moment/src \
90-
rm -rf node_modules/moment/min \
91-
rm -rf node_modules/moment/locale \
89+
../ dist/hapi-server-$(VERSION)
90+
rm -f dist/hapi-server-$(VERSION)/*.md
91+
rm -rf dist/hapi-server-$(VERSION)/.git*
92+
rm -rf dist/hapi-server-$(VERSION)/node_modules/moment/src
93+
rm -rf dist/hapi-server-$(VERSION)/node_modules/moment/min
94+
rm -rf dist/hapi-server-$(VERSION)/node_modules/moment/locale
9295

9396
clean:
9497
rm -rf dist/

server.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -602,16 +602,15 @@ function data(req,res,catalog,header,include) {
602602
}
603603
});
604604

605-
child.stdout.on('end', function() {})
606-
607605
// TODO: Write this to log file
608606
child.stderr.on('data', function (err) {
609607
console.log(ds() + "Error message: " + clc.red(err.toString().trim()));
610608
})
611609

612610
var writing = false;
613611
var exited = false;
614-
child.on('exit', function (code) {
612+
613+
child.on('close', function (code) {
615614
exited = true;
616615

617616
if (code != 0) {
@@ -679,10 +678,10 @@ function data(req,res,catalog,header,include) {
679678
}
680679
if (header["format"] === "json") {
681680
if (!convert) {
682-
var writing = true;
681+
//var writing = true;
683682
res.write(buffer.toString());
684-
var writing = false;
685-
if (exited) {res.end();}
683+
//var writing = false;
684+
//if (exited) {res.end();}
686685
return;
687686
} else {
688687
// JSON requested and CL program cannot produce it.

0 commit comments

Comments
 (0)