From 0f95de1d871a5b7612f6f234234ca162031a622f Mon Sep 17 00:00:00 2001 From: Luigi Pinca Date: Mon, 6 Feb 2017 10:55:36 +0100 Subject: [PATCH] [minor] Use prebuild --- .gitignore | 7 ++++--- .npmignore | 1 + package.json | 10 +++++++--- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 17d6b1e..122111c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ +node_modules/ +prebuilds/ +coverage/ +build/ npm-debug.log -node_modules -build -coverage diff --git a/.npmignore b/.npmignore index 7dd6291..4bb4179 100644 --- a/.npmignore +++ b/.npmignore @@ -1,3 +1,4 @@ +prebuilds/ coverage/ build/ test/ diff --git a/package.json b/package.json index 3dfbf29..3d626b0 100644 --- a/package.json +++ b/package.json @@ -4,8 +4,9 @@ "description": "Check if a buffer contains valid UTF-8", "main": "index.js", "scripts": { + "install": "prebuild-install || node-gyp rebuild", "coverage": "istanbul cover _mocha --report html -- test/*.test.js", - "test": "mocha test/*.test.js" + "test": "mocha test/*.test.js && prebuild-ci" }, "repository": { "type": "git", @@ -22,10 +23,13 @@ "homepage": "https://github.com/websockets/utf-8-validate", "dependencies": { "bindings": "~1.2.1", - "nan": "~2.5.0" + "nan": "~2.5.0", + "prebuild-install": "~2.1.0" }, "devDependencies": { "istanbul": "~0.4.5", - "mocha": "~3.2.0" + "mocha": "~3.2.0", + "prebuild": "~6.0.2", + "prebuild-ci": "~2.0.0" } }