Skip to content

Commit a8ea52f

Browse files
committed
better tests and fix compile
1 parent 862d63f commit a8ea52f

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

compile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ node_version=$(curl --silent --get --data-urlencode "range=${semver_range}" http
55
node_url="http://s3pository.heroku.com/node/v$node_version/node-v$node_version-linux-x64.tar.gz"
66
curl $node_url -s -o - | tar xzf - -C $(pwd)
77
mv node-v${node_version}-linux-x64 node
8+
ls node/bin
9+
export PATH="$(pwd)/node/bin:${PATH}"
810
mkdir -p ${SERVICE}/bin
9-
install $(ls node/bin/*) ${SERVICE}/bin
1011

1112
exit $?

test

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
11
#!/usr/bin/env bash
22

3-
if ! command -v node 2>&1 > /dev/null; then
3+
if ! command -v node 2>&1 > /dev/null || ! command -v npm 2>&1; then
44
exit ${ERROR}
55
fi
66

7+
npm > /dev/null 2>&1
8+
if (( $? != 0 )); then
9+
exit $?
10+
fi
11+
12+
node -v > /dev/null 2>&1
13+
if (( $? != 0 )); then
14+
exit $?
15+
fi
16+

0 commit comments

Comments
 (0)