New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

sqlite3

Package Overview
Dependencies
Maintainers
4
Versions
103
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sqlite3 - npm Package Compare versions

Comparing version 3.1.6 to 3.1.7

deps/sqlite-autoconf-3150000.tar.gz

5

CHANGELOG.md
# Changelog
## 3.1.7
- Upgrade sqlite to 3.15, enable FTS4, FTS5 (@wmertens)
- Upgrade to node-pre-gyp@0.6.31 and nan@2.4.0
## 3.1.6

@@ -4,0 +9,0 @@

4

node_modules/node-pre-gyp/CHANGELOG.md
# node-pre-gyp changelog
## 0.6.31
- Updated various deps
## 0.6.30

@@ -4,0 +8,0 @@

10

node_modules/node-pre-gyp/lib/install.js

@@ -98,7 +98,5 @@ "use strict";

badDownload = true;
if (res.statusCode == 404) {
return callback(new Error('Pre-built binary not available for your system, looked for ' + from));
} else {
return callback(new Error(res.statusCode + ' status code downloading tarball ' + from));
}
var err = new Error(res.statusCode + ' status code downloading tarball ' + from);
err.statusCode = res.statusCode;
return callback(err);
}

@@ -121,3 +119,3 @@ // start unzipping and untaring

full_message += fallback_message;
log.error("Tried to download: " + opts.hosted_tarball);
log.error("Tried to download(" + err.statusCode + "): " + opts.hosted_tarball);
log.error(full_message);

@@ -124,0 +122,0 @@ log.http(err.message);

@@ -798,2 +798,10 @@ {

},
"0.10.47": {
"node_abi": 11,
"v8": "3.14"
},
"0.10.48": {
"node_abi": 11,
"v8": "3.14"
},
"0.11.0": {

@@ -931,2 +939,10 @@ "node_abi": 12,

},
"0.12.16": {
"node_abi": 14,
"v8": "3.28"
},
"0.12.17": {
"node_abi": 14,
"v8": "3.28"
},
"1.0.0": {

@@ -1188,2 +1204,10 @@ "node_abi": 42,

},
"4.6.0": {
"node_abi": 46,
"v8": "4.5"
},
"4.6.1": {
"node_abi": 46,
"v8": "4.5"
},
"5.0.0": {

@@ -1300,3 +1324,27 @@ "node_abi": 47,

"v8": "5.1"
},
"6.6.0": {
"node_abi": 48,
"v8": "5.1"
},
"6.7.0": {
"node_abi": 48,
"v8": "5.1"
},
"6.8.0": {
"node_abi": 48,
"v8": "5.1"
},
"6.8.1": {
"node_abi": 48,
"v8": "5.1"
},
"6.9.0": {
"node_abi": 48,
"v8": "5.1"
},
"6.9.1": {
"node_abi": 48,
"v8": "5.1"
}
}

@@ -40,3 +40,3 @@ {

"_shasum": "30057438eac6cf7f8c4767f38648d6697d75c903",
"_from": "mkdirp@>=0.5.0 <0.6.0",
"_from": "mkdirp@>=0.5.1 <0.6.0",
"_npmVersion": "2.9.0",

@@ -43,0 +43,0 @@ "_nodeVersion": "2.0.0",

@@ -35,3 +35,3 @@ {

"_shasum": "c6465dbf08abcd4db359317f79ac68a646b28ff9",
"_from": "nopt@>=3.0.1 <3.1.0",
"_from": "nopt@>=3.0.6 <3.1.0",
"_npmVersion": "2.14.10",

@@ -38,0 +38,0 @@ "_nodeVersion": "4.2.1",

@@ -42,3 +42,3 @@ {

"_shasum": "43651b76b6ae53b5c802f1151fa3fc3b059969c9",
"_from": "rc@>=1.1.0 <1.2.0",
"_from": "rc@>=1.1.6 <1.2.0",
"_npmVersion": "3.5.1",

@@ -45,0 +45,0 @@ "_nodeVersion": "4.2.3",

@@ -55,2 +55,4 @@ var aws4 = exports,

request.hostname = headers.Host || headers.host
this.isCodeCommitGit = this.service === 'codecommit' && request.method === 'GIT'
}

@@ -113,3 +115,3 @@

if (!request.doNotModifyHeaders) {
if (!request.doNotModifyHeaders && !this.isCodeCommitGit) {
if (request.body && !headers['Content-Type'] && !headers['content-type'])

@@ -158,2 +160,5 @@ headers['Content-Type'] = 'application/x-www-form-urlencoded; charset=utf-8'

this.datetime = date.toISOString().replace(/[:\-]|\.\d{3}/g, '')
// Remove the trailing 'Z' on the timestamp string for CodeCommit git access
if (this.isCodeCommitGit) this.datetime = this.datetime.slice(0, -1)
}

@@ -208,4 +213,4 @@ return this.datetime

firstValOnly = this.service === 's3',
bodyHash = this.service === 's3' && this.request.signQuery ?
'UNSIGNED-PAYLOAD' : hash(this.request.body || '', 'hex')
bodyHash = this.service === 's3' && this.request.signQuery ? 'UNSIGNED-PAYLOAD' :
(this.isCodeCommitGit ? '' : hash(this.request.body || '', 'hex'))

@@ -212,0 +217,0 @@ if (query) {

{
"name": "aws4",
"version": "1.4.1",
"version": "1.5.0",
"description": "Signs and prepares requests using AWS Signature Version 4",

@@ -75,3 +75,3 @@ "author": {

},
"gitHead": "f126d3ff80be1ddde0fc6b50bb51a7f199547e81",
"gitHead": "ba136334ee08884c6042c8578a22e376233eef34",
"bugs": {

@@ -81,7 +81,7 @@ "url": "https://github.com/mhart/aws4/issues"

"homepage": "https://github.com/mhart/aws4#readme",
"_id": "aws4@1.4.1",
"_shasum": "fde7d5292466d230e5ee0f4e038d9dfaab08fc61",
"_id": "aws4@1.5.0",
"_shasum": "0a29ffb79c31c9e712eeb087e8e7a64b4a56d755",
"_from": "aws4@>=1.2.1 <2.0.0",
"_npmVersion": "2.15.4",
"_nodeVersion": "4.4.3",
"_npmVersion": "2.15.11",
"_nodeVersion": "4.5.0",
"_npmUser": {

@@ -98,12 +98,12 @@ "name": "hichaelmart",

"dist": {
"shasum": "fde7d5292466d230e5ee0f4e038d9dfaab08fc61",
"tarball": "https://registry.npmjs.org/aws4/-/aws4-1.4.1.tgz"
"shasum": "0a29ffb79c31c9e712eeb087e8e7a64b4a56d755",
"tarball": "https://registry.npmjs.org/aws4/-/aws4-1.5.0.tgz"
},
"_npmOperationalInternal": {
"host": "packages-12-west.internal.npmjs.com",
"tmp": "tmp/aws4-1.4.1.tgz_1462643218465_0.6527479749638587"
"host": "packages-16-east.internal.npmjs.com",
"tmp": "tmp/aws4-1.5.0.tgz_1476226259635_0.2796843808609992"
},
"directories": {},
"_resolved": "https://registry.npmjs.org/aws4/-/aws4-1.4.1.tgz",
"_resolved": "https://registry.npmjs.org/aws4/-/aws4-1.5.0.tgz",
"readme": "ERROR: No README data found!"
}

@@ -437,2 +437,11 @@ aws4

*/
// Generate CodeCommit Git access password
var signer = new aws4.RequestSigner({
service: 'codecommit',
host: 'git-codecommit.us-east-1.amazonaws.com',
method: 'GIT',
path: '/v1/repos/MyAwesomeRepo',
})
var password = signer.getDateTime() + 'Z' + signer.signature()
```

@@ -439,0 +448,0 @@

@@ -90,3 +90,3 @@ {

"_shasum": "d2b8268a286da13eaa5d01adf5d18cc90f657d93",
"_from": "request@>=2.0.0 <3.0.0",
"_from": "request@>=2.75.0 <3.0.0",
"_npmVersion": "2.15.9",

@@ -93,0 +93,0 @@ "_nodeVersion": "6.5.0",

@@ -106,3 +106,7 @@ exports.alphasort = alphasort

self.cwdAbs = makeAbs(self, self.cwd)
// TODO: is an absolute `cwd` supposed to be resolved against `root`?
// e.g. { cwd: '/test', root: __dirname } === path.join(__dirname, '/test')
self.cwdAbs = isAbsolute(self.cwd) ? self.cwd : makeAbs(self, self.cwd)
if (process.platform === "win32")
self.cwdAbs = self.cwdAbs.replace(/\\/g, "/")
self.nomount = !!options.nomount

@@ -109,0 +113,0 @@

@@ -468,3 +468,3 @@ // Approach:

var abs = this._makeAbs(e)
var abs = isAbsolute(e) ? e : this._makeAbs(e)

@@ -512,6 +512,6 @@ if (this.mark)

function lstatcb_ (er, lstat) {
if (er)
if (er && er.code === 'ENOENT')
return cb()
var isSym = lstat.isSymbolicLink()
var isSym = lstat && lstat.isSymbolicLink()
self.symlinks[abs] = isSym

@@ -521,3 +521,3 @@

// don't bother doing a readdir in that case.
if (!isSym && !lstat.isDirectory()) {
if (!isSym && lstat && !lstat.isDirectory()) {
self.cache[abs] = 'FILE'

@@ -775,3 +775,3 @@ cb()

Glob.prototype._stat2 = function (f, abs, er, stat, cb) {
if (er) {
if (er && (er.code === 'ENOENT' || er.code === 'ENOTDIR')) {
this.statCache[abs] = false

@@ -784,9 +784,11 @@ return cb()

if (abs.slice(-1) === '/' && !stat.isDirectory())
if (abs.slice(-1) === '/' && stat && !stat.isDirectory())
return cb(null, false, stat)
var c = stat.isDirectory() ? 'DIR' : 'FILE'
var c = true
if (stat)
c = stat.isDirectory() ? 'DIR' : 'FILE'
this.cache[abs] = this.cache[abs] || c
if (needDir && c !== 'DIR')
if (needDir && c === 'FILE')
return cb()

@@ -793,0 +795,0 @@

@@ -22,15 +22,25 @@ var wrappy = require('wrappy')

var args = slice(arguments)
for (var i = 0; i < len; i++) {
cbs[i].apply(null, args)
// XXX It's somewhat ambiguous whether a new callback added in this
// pass should be queued for later execution if something in the
// list of callbacks throws, or if it should just be discarded.
// However, it's such an edge case that it hardly matters, and either
// choice is likely as surprising as the other.
// As it happens, we do go ahead and schedule it for later execution.
try {
for (var i = 0; i < len; i++) {
cbs[i].apply(null, args)
}
} finally {
if (cbs.length > len) {
// added more in the interim.
// de-zalgo, just in case, but don't call again.
cbs.splice(0, len)
process.nextTick(function () {
RES.apply(null, args)
})
} else {
delete reqs[key]
}
}
if (cbs.length > len) {
// added more in the interim.
// de-zalgo, just in case, but don't call again.
cbs.splice(0, len)
process.nextTick(function () {
RES.apply(null, args)
})
} else {
delete reqs[key]
}
})

@@ -37,0 +47,0 @@ }

{
"name": "inflight",
"version": "1.0.5",
"version": "1.0.6",
"description": "Add callbacks to requests in flight to avoid async duplication",

@@ -14,6 +14,6 @@ "main": "inflight.js",

"devDependencies": {
"tap": "^1.2.0"
"tap": "^7.1.2"
},
"scripts": {
"test": "tap test.js"
"test": "tap test.js --100"
},

@@ -34,15 +34,15 @@ "repository": {

"license": "ISC",
"gitHead": "559e37b4f6327fca797fe8d7fe8ed6d9cae08821",
"_id": "inflight@1.0.5",
"_shasum": "db3204cd5a9de2e6cd890b85c6e2f66bcf4f620a",
"gitHead": "a547881738c8f57b27795e584071d67cf6ac1a57",
"_id": "inflight@1.0.6",
"_shasum": "49bd6331d7d02d0c09bc910a1075ba8165b56df9",
"_from": "inflight@>=1.0.4 <2.0.0",
"_npmVersion": "3.9.1",
"_nodeVersion": "5.10.1",
"_npmVersion": "3.10.7",
"_nodeVersion": "6.5.0",
"_npmUser": {
"name": "zkat",
"email": "kat@sykosomatic.org"
"name": "isaacs",
"email": "i@izs.me"
},
"dist": {
"shasum": "db3204cd5a9de2e6cd890b85c6e2f66bcf4f620a",
"tarball": "https://registry.npmjs.org/inflight/-/inflight-1.0.5.tgz"
"shasum": "49bd6331d7d02d0c09bc910a1075ba8165b56df9",
"tarball": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz"
},

@@ -68,8 +68,8 @@ "maintainers": [

"_npmOperationalInternal": {
"host": "packages-12-west.internal.npmjs.com",
"tmp": "tmp/inflight-1.0.5.tgz_1463529611443_0.00041943578980863094"
"host": "packages-16-east.internal.npmjs.com",
"tmp": "tmp/inflight-1.0.6.tgz_1476330807696_0.10388551792129874"
},
"directories": {},
"_resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.5.tgz",
"_resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
"readme": "ERROR: No README data found!"
}

@@ -9,3 +9,3 @@ {

"description": "a little globber",
"version": "7.1.0",
"version": "7.1.1",
"repository": {

@@ -48,3 +48,3 @@ "type": "git",

"license": "ISC",
"gitHead": "f65f9eb7eda113528c5257b58fac4ca685ee6c4f",
"gitHead": "bc8d43b736a98a9e289fdfceee9266cff35e5742",
"bugs": {

@@ -54,4 +54,4 @@ "url": "https://github.com/isaacs/node-glob/issues"

"homepage": "https://github.com/isaacs/node-glob#readme",
"_id": "glob@7.1.0",
"_shasum": "36add856d746d0d99e4cc2797bba1ae2c67272fd",
"_id": "glob@7.1.1",
"_shasum": "805211df04faaf1c63a3600306cdf5ade50b2ec8",
"_from": "glob@>=7.0.5 <8.0.0",

@@ -65,4 +65,4 @@ "_npmVersion": "3.10.7",

"dist": {
"shasum": "36add856d746d0d99e4cc2797bba1ae2c67272fd",
"tarball": "https://registry.npmjs.org/glob/-/glob-7.1.0.tgz"
"shasum": "805211df04faaf1c63a3600306cdf5ade50b2ec8",
"tarball": "https://registry.npmjs.org/glob/-/glob-7.1.1.tgz"
},

@@ -76,8 +76,8 @@ "maintainers": [

"_npmOperationalInternal": {
"host": "packages-12-west.internal.npmjs.com",
"tmp": "tmp/glob-7.1.0.tgz_1474396131090_0.08145137410610914"
"host": "packages-16-east.internal.npmjs.com",
"tmp": "tmp/glob-7.1.1.tgz_1475876991562_0.924720095237717"
},
"directories": {},
"_resolved": "https://registry.npmjs.org/glob/-/glob-7.1.0.tgz",
"_resolved": "https://registry.npmjs.org/glob/-/glob-7.1.1.tgz",
"readme": "ERROR: No README data found!"
}

@@ -253,7 +253,9 @@ module.exports = globSync

} catch (er) {
// lstat failed, doesn't exist
return null
if (er.code === 'ENOENT') {
// lstat failed, doesn't exist
return null
}
}
var isSym = lstat.isSymbolicLink()
var isSym = lstat && lstat.isSymbolicLink()
this.symlinks[abs] = isSym

@@ -263,3 +265,3 @@

// don't bother doing a readdir in that case.
if (!isSym && !lstat.isDirectory())
if (!isSym && lstat && !lstat.isDirectory())
this.cache[abs] = 'FILE'

@@ -449,6 +451,9 @@ else

} catch (er) {
return false
if (er && (er.code === 'ENOENT' || er.code === 'ENOTDIR')) {
this.statCache[abs] = false
return false
}
}
if (lstat.isSymbolicLink()) {
if (lstat && lstat.isSymbolicLink()) {
try {

@@ -466,6 +471,9 @@ stat = fs.statSync(abs)

var c = stat.isDirectory() ? 'DIR' : 'FILE'
var c = true
if (stat)
c = stat.isDirectory() ? 'DIR' : 'FILE'
this.cache[abs] = this.cache[abs] || c
if (needDir && c !== 'DIR')
if (needDir && c === 'FILE')
return false

@@ -472,0 +480,0 @@

@@ -42,3 +42,3 @@ {

"_shasum": "96800093cbf1a0c86bd95b4625467535c29dfa04",
"_from": "rimraf@>=2.5.0 <2.6.0",
"_from": "rimraf@>=2.5.4 <2.6.0",
"_npmVersion": "3.10.6",

@@ -45,0 +45,0 @@ "_nodeVersion": "4.4.4",

@@ -58,3 +58,3 @@ "use strict"

// non-compliant tar implementations.
var tarPack = tar.Pack({ noProprietary: options.noProprietary || false })
var tarPack = tar.Pack({ noProprietary: options.noProprietary || false, fromBase: options.fromBase || false })
var gzip = zlib.Gzip()

@@ -96,2 +96,3 @@

var defaultName = options.defaultName || (options.defaultName === false ? false : 'index.js')
var strip = (options.strip !== undefined) ? options.strip : 1

@@ -113,13 +114,17 @@ // figure out who we're supposed to be, if we're not pretending

})
rm(unpackTarget, function (er) {
if (er) {
tarball.emit('error', er)
return tarball.end()
}
if (0 === --pending) next()
})
if (!options.keepFiles) {
rm(unpackTarget, function (er) {
if (er) {
tarball.emit('error', er)
return tarball.end()
}
if (0 === --pending) next()
})
} else {
next()
}
function next() {
// gzip {tarball} --decompress --stdout \
// | tar -mvxpf - --strip-components=1 -C {unpackTarget}
gunzTarPerm(tarball, unpackTarget, dMode, fMode, uid, gid, defaultName)
// | tar -mvxpf - --strip-components={strip} -C {unpackTarget}
gunzTarPerm(tarball, unpackTarget, dMode, fMode, uid, gid, defaultName, strip)
}

@@ -130,3 +135,3 @@ return tarball

function gunzTarPerm(tarball, target, dMode, fMode, uid, gid, defaultName) {
function gunzTarPerm(tarball, target, dMode, fMode, uid, gid, defaultName, strip) {
debug('modes %j', [dMode.toString(8), fMode.toString(8)])

@@ -152,3 +157,3 @@

var extractOpts = { type: 'Directory', path: target, strip: 1 }
var extractOpts = { type: 'Directory', path: target, strip: strip }

@@ -155,0 +160,0 @@ if (!win32 && typeof uid === 'number' && typeof gid === 'number') {

@@ -49,3 +49,3 @@ {

"_shasum": "f87057e995b1a1f6ae6a4960664137bc56f039da",
"_from": "debug@2.2.0",
"_from": "debug@>=2.2.0 <2.3.0",
"_npmVersion": "2.7.4",

@@ -52,0 +52,0 @@ "_nodeVersion": "0.12.2",

{
"name": "tar-pack",
"version": "3.1.4",
"version": "3.3.0",
"description": "Package and un-package modules of some sort (in tar/gz bundles).",

@@ -28,3 +28,3 @@ "scripts": {

},
"gitHead": "ee23170716772ae458574ea090500035202c7c64",
"gitHead": "fbf436f8662eeb894a7a23372b5219e893648744",
"bugs": {

@@ -34,11 +34,15 @@ "url": "https://github.com/ForbesLindesay/tar-pack/issues"

"homepage": "https://github.com/ForbesLindesay/tar-pack#readme",
"_id": "tar-pack@3.1.4",
"_shasum": "bc8cf9a22f5832739f12f3910dac1eb97b49708c",
"_from": "tar-pack@>=3.1.0 <3.2.0",
"_npmVersion": "3.10.2",
"_nodeVersion": "6.2.2",
"_id": "tar-pack@3.3.0",
"_shasum": "30931816418f55afc4d21775afdd6720cee45dae",
"_from": "tar-pack@>=3.3.0 <3.4.0",
"_npmVersion": "3.8.6",
"_nodeVersion": "5.12.0",
"_npmUser": {
"name": "shinnn",
"email": "snnskwtnb@gmail.com"
"name": "es128",
"email": "elan.shanker+npm@gmail.com"
},
"dist": {
"shasum": "30931816418f55afc4d21775afdd6720cee45dae",
"tarball": "https://registry.npmjs.org/tar-pack/-/tar-pack-3.3.0.tgz"
},
"maintainers": [

@@ -58,13 +62,9 @@ {

],
"dist": {
"shasum": "bc8cf9a22f5832739f12f3910dac1eb97b49708c",
"tarball": "https://registry.npmjs.org/tar-pack/-/tar-pack-3.1.4.tgz"
},
"_npmOperationalInternal": {
"host": "packages-12-west.internal.npmjs.com",
"tmp": "tmp/tar-pack-3.1.4.tgz_1467088357244_0.18669610540382564"
"host": "packages-16-east.internal.npmjs.com",
"tmp": "tmp/tar-pack-3.3.0.tgz_1476732228172_0.9373016993049532"
},
"directories": {},
"_resolved": "https://registry.npmjs.org/tar-pack/-/tar-pack-3.1.4.tgz",
"_resolved": "https://registry.npmjs.org/tar-pack/-/tar-pack-3.3.0.tgz",
"readme": "ERROR: No README data found!"
}

@@ -28,2 +28,3 @@ # Tar Pack

- `noProprietary` (defaults to `false`) Set this to `true` to prevent any proprietary attributes being added to the tarball. These attributes are allowed by the spec, but may trip up some poorly written tarball parsers.
- `fromBase` (defaults to `false`) Set this to `true` to make sure your tarballs root is the directory you pass in.
- `ignoreFiles` (defaults to `['.gitignore']`) These files can specify files to be excluded from the package using the syntax of `.gitignore`. This option is ignored if you parse a `fstream.DirReader` instead of a string for folder.

@@ -67,2 +68,4 @@ - `filter` (defaults to `entry => true`) A function that takes an entry and returns `true` if it should be included in the package and `false` if it should not. Entryies are of the form `{path, basename, dirname, type}` where (type is "Directory" or "File"). This function is ignored if you parse a `fstream.DirReader` instead of a string for folder.

- `unsafe` - (defaults to `false`) (on non win32 OSes it overrides `gid` and `uid` with the current processes IDs)
- `strip` - (defaults to `1`) Number of path segments to strip from the root when extracting
- `keepFiles` - (defaults to `false`) Set this to `true` to prevent target directory to be removed. Extracted files overwrite existing files.

@@ -83,2 +86,2 @@ Example:

BSD
BSD

@@ -26,3 +26,23 @@ var tar = require('../')

})
it('unpacks the tarball into the directory without deleting existing files', function (done) {
read(__dirname + '/fixtures/packed-file.txt').pipe(tar.unpack(__dirname + '/output/unpacked', function (err) {
if (err) return done(err)
read(__dirname + '/fixtures/packed.tar').pipe(tar.unpack(__dirname + '/output/unpacked', {keepFiles: true}, function (err) {
if (err) return done(err)
assert.equal(rfile('./output/unpacked/index.js'), rfile('./fixtures/packed-file.txt'))
done()
}))
}))
})
})
describe('tarball.pipe(unpack(directory, { strip: 0 }, callback))', function () {
it('unpacks the tarball into the directory with subdir package', function (done) {
read(__dirname + '/fixtures/packed.tar').pipe(tar.unpack(__dirname + '/output/unpacked', { strip: 0 } , function (err) {
if (err) return done(err)
assert.equal(rfile('./output/unpacked/package/bar.txt'), rfile('./fixtures/to-pack/bar.txt'))
assert.equal(rfile('./output/unpacked/package/foo.txt'), rfile('./fixtures/to-pack/foo.txt'))
done()
}))
})
})
describe('gziptarball.pipe(unpack(directory, callback))', function () {

@@ -68,2 +88,24 @@ it('unpacks the tarball into the directory', function (done) {

})
})
})
describe('pack(directory, { fromBase: true }).pipe(tarball)', function () {
it('packs the directory with input dir as base dir', function (done) {
var called = false
mkdir(__dirname + '/output/')
tar.pack(__dirname + '/fixtures/to-pack', { fromBase: true }).pipe(write(__dirname + '/output/packed.tar.gz'))
.on('error', function (err) {
if (called) return
called = true
done(err)
})
.on('close', function () {
if (called) return
called = true
read(__dirname + '/output/packed.tar.gz').pipe(tar.unpack(__dirname + '/output/unpacked', { strip: 0 }, function (err) {
if (err) return done(err)
assert.equal(rfile('./output/unpacked/bar.txt'), rfile('./fixtures/to-pack/bar.txt'))
assert.equal(rfile('./output/unpacked/foo.txt'), rfile('./fixtures/to-pack/foo.txt'))
done()
}))
})
})
})

@@ -39,3 +39,3 @@ {

"_shasum": "604e8a92fe26ffd9f6fae30399d4984e1ab22822",
"_from": "fstream@>=1.0.10 <1.1.0",
"_from": "fstream@>=1.0.2 <2.0.0",
"_npmVersion": "3.10.0",

@@ -42,0 +42,0 @@ "_nodeVersion": "4.4.5",

@@ -37,3 +37,3 @@ {

"_shasum": "8e4d2a256c0e2185c6b18ad694aec968b83cb1d1",
"_from": "tar@>=2.2.0 <2.3.0",
"_from": "tar@>=2.2.1 <2.3.0",
"_npmVersion": "2.14.3",

@@ -40,0 +40,0 @@ "_nodeVersion": "2.2.2",

{
"name": "node-pre-gyp",
"description": "Node.js native addon binary install tool",
"version": "0.6.30",
"version": "0.6.31",
"keywords": [

@@ -28,16 +28,16 @@ "native",

"dependencies": {
"mkdirp": "~0.5.0",
"nopt": "~3.0.1",
"npmlog": "4.x",
"rc": "~1.1.0",
"request": "2.x",
"rimraf": "~2.5.0",
"mkdirp": "~0.5.1",
"nopt": "~3.0.6",
"npmlog": "^4.0.0",
"rc": "~1.1.6",
"request": "^2.75.0",
"rimraf": "~2.5.4",
"semver": "~5.3.0",
"tar": "~2.2.0",
"tar-pack": "~3.1.0"
"tar": "~2.2.1",
"tar-pack": "~3.3.0"
},
"devDependencies": {
"aws-sdk": "2.x",
"mocha": "2.x",
"retire": "1.1.2",
"mocha": "3.x",
"retire": "1.2.10",
"jshint": "2.x"

@@ -58,3 +58,5 @@ },

},
"gitHead": "74f4d836f24ce2efec339ad2abe50703a9793185",
"readme": "# node-pre-gyp\n\n#### node-pre-gyp makes it easy to publish and install Node.js C++ addons from binaries\n\n[![NPM](https://nodei.co/npm/node-pre-gyp.png?downloads=true&downloadRank=true)](https://nodei.co/npm/node-pre-gyp/)\n\n[![Build Status](https://api.travis-ci.org/mapbox/node-pre-gyp.svg)](https://travis-ci.org/mapbox/node-pre-gyp)\n[![Build status](https://ci.appveyor.com/api/projects/status/3nxewb425y83c0gv)](https://ci.appveyor.com/project/Mapbox/node-pre-gyp)\n[![Dependencies](https://david-dm.org/mapbox/node-pre-gyp.svg)](https://david-dm.org/mapbox/node-pre-gyp)\n\n`node-pre-gyp` stands between [npm](https://github.com/npm/npm) and [node-gyp](https://github.com/Tootallnate/node-gyp) and offers a cross-platform method of binary deployment.\n\n### Features\n\n - A command line tool called `node-pre-gyp` that can install your package's C++ module from a binary.\n - A variety of developer targeted commands for packaging, testing, and publishing binaries.\n - A JavaScript module that can dynamically require your installed binary: `require('node-pre-gyp').find`\n\nFor a hello world example of a module packaged with `node-pre-gyp` see <https://github.com/springmeyer/node-addon-example> and [the wiki ](https://github.com/mapbox/node-pre-gyp/wiki/Modules-using-node-pre-gyp) for real world examples.\n\n## Credits\n\n - The module is modeled after [node-gyp](https://github.com/Tootallnate/node-gyp) by [@Tootallnate](https://github.com/Tootallnate)\n - Motivation for initial development came from [@ErisDS](https://github.com/ErisDS) and the [Ghost Project](https://github.com/TryGhost/Ghost).\n - Development is sponsored by [Mapbox](https://www.mapbox.com/)\n\n## FAQ\n\nSee the [Frequently Ask Questions](https://github.com/mapbox/node-pre-gyp/wiki/FAQ).\n\n## Depends\n\n - Node.js >= node v0.10.x\n\n## Install\n\n`node-pre-gyp` is designed to be installed as a local dependency of your Node.js C++ addon and accessed like:\n\n ./node_modules/.bin/node-pre-gyp --help\n\nBut you can also install it globally:\n\n npm install node-pre-gyp -g\n\n## Usage\n\n### Commands\n\nView all possible commands:\n\n node-pre-gyp --help\n\n- clean - Remove the entire folder containing the compiled .node module\n- install - Install pre-built binary for module\n- reinstall - Run \"clean\" and \"install\" at once\n- build - Compile the module by dispatching to node-gyp or nw-gyp\n- rebuild - Run \"clean\" and \"build\" at once\n- package - Pack binary into tarball\n- testpackage - Test that the staged package is valid\n- publish - Publish pre-built binary\n- unpublish - Unpublish pre-built binary\n- info - Fetch info on published binaries\n\nYou can also chain commands:\n\n node-pre-gyp clean build unpublish publish info\n\n### Options\n\nOptions include:\n\n - `-C/--directory`: run the command in this directory\n - `--build-from-source`: build from source instead of using pre-built binary\n - `--update-binary`: reinstall by replacing previously installed local binary with remote binary\n - `--runtime=node-webkit`: customize the runtime: `node`, `electron` and `node-webkit` are the valid options\n - `--fallback-to-build`: fallback to building from source if pre-built binary is not available\n - `--target=0.10.25`: Pass the target node or node-webkit version to compile against\n - `--target_arch=ia32`: Pass the target arch and override the host `arch`. Valid values are 'ia32','x64', or `arm`.\n - `--target_platform=win32`: Pass the target platform and override the host `platform`. Valid values are `linux`, `darwin`, `win32`, `sunos`, `freebsd`, `openbsd`, and `aix`.\n\nBoth `--build-from-source` and `--fallback-to-build` can be passed alone or they can provide values. You can pass `--fallback-to-build=false` to override the option as declared in package.json. In addition to being able to pass `--build-from-source` you can also pass `--build-from-source=myapp` where `myapp` is the name of your module.\n\nFor example: `npm install --build-from-source=myapp`. This is useful if:\n\n - `myapp` is referenced in the package.json of a larger app and therefore `myapp` is being installed as a dependent with `npm install`.\n - The larger app also depends on other modules installed with `node-pre-gyp`\n - You only want to trigger a source compile for `myapp` and the other modules.\n\n### Configuring\n\nThis is a guide to configuring your module to use node-pre-gyp.\n\n#### 1) Add new entries to your `package.json`\n\n - Add `node-pre-gyp` to `dependencies`\n - Add `aws-sdk` as a `devDependency`\n - Add a custom `install` script\n - Declare a `binary` object\n\nThis looks like:\n\n```js\n \"dependencies\" : {\n \"node-pre-gyp\": \"0.6.x\"\n },\n \"devDependencies\": {\n \"aws-sdk\": \"2.x\"\n }\n \"scripts\": {\n \"preinstall\": \"npm install node-pre-gyp\",\n \"install\": \"node-pre-gyp install --fallback-to-build\"\n },\n \"binary\": {\n \"module_name\": \"your_module\",\n \"module_path\": \"./lib/binding/\",\n \"host\": \"https://your_module.s3-us-west-1.amazonaws.com\"\n }\n```\n\nFor a full example see [node-addon-examples's package.json](https://github.com/springmeyer/node-addon-example/blob/master/package.json).\n\n##### The `binary` object has three required properties\n\n###### module_name\n\nThe name of your native node module. This value must:\n\n - Match the name passed to [the NODE_MODULE macro](http://nodejs.org/api/addons.html#addons_hello_world)\n - Must be a valid C variable name (e.g. it cannot contain `-`)\n - Should not include the `.node` extension.\n\n###### module_path\n\nThe location your native module is placed after a build. This should be an empty directory without other Javascript files. This entire directory will be packaged in the binary tarball. When installing from a remote package this directory will be overwritten with the contents of the tarball.\n\nNote: This property supports variables based on [Versioning](#versioning).\n\n###### host\n\nA url to the remote location where you've published tarball binaries (must be `https` not `http`).\n\nIt is highly recommended that you use Amazon S3. The reasons are:\n\n - Various node-pre-gyp commands like `publish` and `info` only work with an S3 host.\n - S3 is a very solid hosting platform for distributing large files.\n - We provide detail documentation for using [S3 hosting](#s3-hosting) with node-pre-gyp.\n\nWhy then not require S3? Because while some applications using node-pre-gyp need to distribute binaries as large as 20-30 MB, others might have very small binaries and might wish to store them in a GitHub repo. This is not recommended, but if an author really wants to host in a non-s3 location then it should be possible.\n\nIt should also be mentioned that there is an optional and entirely separate npm module called [node-pre-gyp-github](https://github.com/bchr02/node-pre-gyp-github) which is intended to complement node-pre-gyp and be installed along with it. It provides the ability to store and publish your binaries within your repositories GitHub Releases if you would rather not use S3 directly. Installation and usage instructions can be found [here](https://github.com/bchr02/node-pre-gyp-github), but the basic premise is that instead of using the ```node-pre-gyp publish``` command you would use ```node-pre-gyp-github publish```.\n\n##### The `binary` object has two optional properties\n\n###### remote_path\n\nIt **is recommended** that you customize this property. This is an extra path to use for publishing and finding remote tarballs. The default value for `remote_path` is `\"\"` meaning that if you do not provide it then all packages will be published at the base of the `host`. It is recommended to provide a value like `./{name}/v{version}` to help organize remote packages in the case that you choose to publish multiple node addons to the same `host`.\n\nNote: This property supports variables based on [Versioning](#versioning).\n\n###### package_name\n\nIt is **not recommended** to override this property unless you are also overriding the `remote_path`. This is the versioned name of the remote tarball containing the binary `.node` module and any supporting files you've placed inside the `module_path` directory. Unless you specify `package_name` in your `package.json` then it defaults to `{module_name}-v{version}-{node_abi}-{platform}-{arch}.tar.gz` which allows your binary to work across node versions, platforms, and architectures. If you are using `remote_path` that is also versioned by `./{module_name}/v{version}` then you could remove these variables from the `package_name` and just use: `{node_abi}-{platform}-{arch}.tar.gz`. Then your remote tarball will be looked up at, for example, `https://example.com/your-module/v0.1.0/node-v11-linux-x64.tar.gz`.\n\nAvoiding the version of your module in the `package_name` and instead only embedding in a directory name can be useful when you want to make a quick tag of your module that does not change any C++ code. In this case you can just copy binaries to the new version behind the scenes like:\n\n```sh\naws s3 sync --acl public-read s3://mapbox-node-binary/sqlite3/v3.0.3/ s3://mapbox-node-binary/sqlite3/v3.0.4/\n```\n\nNote: This property supports variables based on [Versioning](#versioning).\n\n#### 2) Add a new target to binding.gyp\n\n`node-pre-gyp` calls out to `node-gyp` to compile the module and passes variables along like [module_name](#module_name) and [module_path](#module_path).\n\nA new target must be added to `binding.gyp` that moves the compiled `.node` module from `./build/Release/module_name.node` into the directory specified by `module_path`.\n\nAdd a target like this at the end of your `targets` list:\n\n```js\n {\n \"target_name\": \"action_after_build\",\n \"type\": \"none\",\n \"dependencies\": [ \"<(module_name)\" ],\n \"copies\": [\n {\n \"files\": [ \"<(PRODUCT_DIR)/<(module_name).node\" ],\n \"destination\": \"<(module_path)\"\n }\n ]\n }\n```\n\nFor a full example see [node-addon-example's binding.gyp](https://github.com/springmeyer/node-addon-example/blob/2ff60a8ded7f042864ad21db00c3a5a06cf47075/binding.gyp).\n\n#### 3) Dynamically require your `.node`\n\nInside the main js file that requires your addon module you are likely currently doing:\n\n```js\nvar binding = require('../build/Release/binding.node');\n```\n\nor:\n\n```js\nvar bindings = require('./bindings')\n```\n\nChange those lines to:\n\n```js\nvar binary = require('node-pre-gyp');\nvar path = require('path');\nvar binding_path = binary.find(path.resolve(path.join(__dirname,'./package.json')));\nvar binding = require(binding_path);\n```\n\nFor a full example see [node-addon-example's index.js](https://github.com/springmeyer/node-addon-example/blob/2ff60a8ded7f042864ad21db00c3a5a06cf47075/index.js#L1-L4)\n\n#### 4) Build and package your app\n\nNow build your module from source:\n\n npm install --build-from-source\n\nThe `--build-from-source` tells `node-pre-gyp` to not look for a remote package and instead dispatch to node-gyp to build.\n\nNow `node-pre-gyp` should now also be installed as a local dependency so the command line tool it offers can be found at `./node_modules/.bin/node-pre-gyp`.\n\n#### 5) Test\n\nNow `npm test` should work just as it did before.\n\n#### 6) Publish the tarball\n\nThen package your app:\n\n ./node_modules/.bin/node-pre-gyp package\n\nOnce packaged, now you can publish:\n\n ./node_modules/.bin/node-pre-gyp publish\n\nCurrently the `publish` command pushes your binary to S3. This requires:\n\n - You have installed `aws-sdk` with `npm install aws-sdk`\n - You have created a bucket already.\n - The `host` points to an S3 http or https endpoint.\n - You have configured node-pre-gyp to read your S3 credentials (see [S3 hosting](#s3-hosting) for details).\n\nYou can also host your binaries elsewhere. To do this requires:\n\n - You manually publish the binary created by the `package` command to an `https` endpoint\n - Ensure that the `host` value points to your custom `https` endpoint.\n\n#### 7) Automate builds\n\nNow you need to publish builds for all the platforms and node versions you wish to support. This is best automated.\n\n - See [Appveyor Automation](#appveyor-automation) for how to auto-publish builds on Windows.\n - See [Travis Automation](#travis-automation) for how to auto-publish builds on OS X and Linux.\n\n#### 8) You're done!\n\nNow publish your module to the npm registry. Users will now be able to install your module from a binary.\n\nWhat will happen is this:\n\n1. `npm install <your package>` will pull from the npm registry\n2. npm will run the `install` script which will call out to `node-pre-gyp`\n3. `node-pre-gyp` will fetch the binary `.node` module and unpack in the right place\n4. Assuming that all worked, you are done\n\nIf a a binary was not available for a given platform and `--fallback-to-build` was used then `node-gyp rebuild` will be called to try to source compile the module.\n\n## S3 Hosting\n\nYou can host wherever you choose but S3 is cheap, `node-pre-gyp publish` expects it, and S3 can be integrated well with [Travis.ci](http://travis-ci.org) to automate builds for OS X and Ubuntu, and with [Appveyor](http://appveyor.com) to automate builds for Windows. Here is an approach to do this:\n\nFirst, get setup locally and test the workflow:\n\n#### 1) Create an S3 bucket\n\nAnd have your **key** and **secret key** ready for writing to the bucket.\n\nIt is recommended to create a IAM user with a policy that only gives permissions to the specific bucket you plan to publish to. This can be done in the [IAM console](https://console.aws.amazon.com/iam/) by: 1) adding a new user, 2) choosing `Attach User Policy`, 3) Using the `Policy Generator`, 4) selecting `Amazon S3` for the service, 5) adding the actions: `DeleteObject`, `GetObject`, `GetObjectAcl`, `ListBucket`, `PutObject`, `PutObjectAcl`, 6) adding an ARN of `arn:aws:s3:::bucket/*` (replacing `bucket` with your bucket name), and finally 7) clicking `Add Statement` and saving the policy. It should generate a policy like:\n\n```js\n{\n \"Version\": \"2012-10-17\",\n \"Statement\": [\n {\n \"Sid\": \"Stmt1394587197000\",\n \"Effect\": \"Allow\",\n \"Action\": [\n \"s3:DeleteObject\",\n \"s3:GetObject\",\n \"s3:GetObjectAcl\",\n \"s3:ListBucket\",\n \"s3:PutObject\",\n \"s3:PutObjectAcl\"\n ],\n \"Resource\": [\n \"arn:aws:s3:::node-pre-gyp-tests/*\"\n ]\n }\n ]\n}\n```\n\n#### 2) Install node-pre-gyp\n\nEither install it globally:\n\n npm install node-pre-gyp -g\n\nOr put the local version on your PATH\n\n export PATH=`pwd`/node_modules/.bin/:$PATH\n\n#### 3) Configure AWS credentials\n\nThere are several ways to do this.\n\nYou can use any of the methods described at http://docs.aws.amazon.com/AWSJavaScriptSDK/guide/node-configuring.html.\n\nOr you can create a `~/.node_pre_gyprc`\n\nOr pass options in any way supported by [RC](https://github.com/dominictarr/rc#standards)\n\nA `~/.node_pre_gyprc` looks like:\n\n```js\n{\n \"accessKeyId\": \"xxx\",\n \"secretAccessKey\": \"xxx\"\n}\n```\n\nAnother way is to use your environment:\n\n export node_pre_gyp_accessKeyId=xxx\n export node_pre_gyp_secretAccessKey=xxx\n\nYou may also need to specify the `region` if it is not explicit in the `host` value you use. The `bucket` can also be specified but it is optional because `node-pre-gyp` will detect it from the `host` value.\n\n#### 4) Package and publish your build\n\nInstall the `aws-sdk`:\n\n npm install aws-sdk\n\nThen publish:\n\n node-pre-gyp package publish\n\nNote: if you hit an error like `Hostname/IP doesn't match certificate's altnames` it may mean that you need to provide the `region` option in your config.\n\n## Appveyor Automation\n\n[Appveyor](http://www.appveyor.com/) can build binaries and publish the results per commit and supports:\n\n - Windows Visual Studio 2013 and related compilers\n - Both 64 bit (x64) and 32 bit (x86) build configurations\n - Multiple Node.js versions\n\nFor an example of doing this see [node-sqlite3's appveyor.yml](https://github.com/mapbox/node-sqlite3/blob/master/appveyor.yml).\n\nBelow is a guide to getting set up:\n\n#### 1) Create a free Appveyor account\n\nGo to https://ci.appveyor.com/signup/free and sign in with your GitHub account.\n\n#### 2) Create a new project\n\nGo to https://ci.appveyor.com/projects/new and select the GitHub repo for your module\n\n#### 3) Add appveyor.yml and push it\n\nOnce you have committed an `appveyor.yml` ([appveyor.yml reference](http://www.appveyor.com/docs/appveyor-yml)) to your GitHub repo and pushed it AppVeyor should automatically start building your project.\n\n#### 4) Create secure variables\n\nEncrypt your S3 AWS keys by going to <https://ci.appveyor.com/tools/encrypt> and hitting the `encrypt` button.\n\nThen paste the result into your `appveyor.yml`\n\n```yml\nenvironment:\n node_pre_gyp_accessKeyId:\n secure: Dn9HKdLNYvDgPdQOzRq/DqZ/MPhjknRHB1o+/lVU8MA=\n node_pre_gyp_secretAccessKey:\n secure: W1rwNoSnOku1r+28gnoufO8UA8iWADmL1LiiwH9IOkIVhDTNGdGPJqAlLjNqwLnL\n```\n\nNOTE: keys are per account but not per repo (this is difference than Travis where keys are per repo but not related to the account used to encrypt them).\n\n#### 5) Hook up publishing\n\nJust put `node-pre-gyp package publish` in your `appveyor.yml` after `npm install`.\n\n#### 6) Publish when you want\n\nYou might wish to publish binaries only on a specific commit. To do this you could borrow from the [Travis CI idea of commit keywords](http://about.travis-ci.org/docs/user/how-to-skip-a-build/) and add special handling for commit messages with `[publish binary]`:\n\n SET CM=%APPVEYOR_REPO_COMMIT_MESSAGE%\n if not \"%CM%\" == \"%CM:[publish binary]=%\" node-pre-gyp --msvs_version=2013 publish\n\nIf your commit message contains special characters (e.g. `&`) this method might fail. An alternative is to use PowerShell, which gives you additional possibilities, like ignoring case by using `ToLower()`:\n\n ps: if($env:APPVEYOR_REPO_COMMIT_MESSAGE.ToLower().Contains('[publish binary]')) { node-pre-gyp --msvs_version=2013 publish }\n\nRemember this publishing is not the same as `npm publish`. We're just talking about the binary module here and not your entire npm package.\n\n## Travis Automation\n\n[Travis](https://travis-ci.org/) can push to S3 after a successful build and supports both:\n\n - Ubuntu Precise and OS X (64 bit)\n - Multiple Node.js versions\n\nFor an example of doing this see [node-add-example's .travis.yml](https://github.com/springmeyer/node-addon-example/blob/2ff60a8ded7f042864ad21db00c3a5a06cf47075/.travis.yml).\n\nNote: if you need 32 bit binaries, this can be done from a 64 bit Travis machine. See [the node-sqlite3 scripts for an example of doing this](https://github.com/mapbox/node-sqlite3/blob/bae122aa6a2b8a45f6b717fab24e207740e32b5d/scripts/build_against_node.sh#L54-L74).\n\nBelow is a guide to getting set up:\n\n#### 1) Install the Travis gem\n\n gem install travis\n\n#### 2) Create secure variables\n\nMake sure you run this command from within the directory of your module.\n\nUse `travis-encrypt` like:\n\n travis encrypt node_pre_gyp_accessKeyId=${node_pre_gyp_accessKeyId}\n travis encrypt node_pre_gyp_secretAccessKey=${node_pre_gyp_secretAccessKey}\n\nThen put those values in your `.travis.yml` like:\n\n```yaml\nenv:\n global:\n - secure: F+sEL/v56CzHqmCSSES4pEyC9NeQlkoR0Gs/ZuZxX1ytrj8SKtp3MKqBj7zhIclSdXBz4Ev966Da5ctmcTd410p0b240MV6BVOkLUtkjZJyErMBOkeb8n8yVfSoeMx8RiIhBmIvEn+rlQq+bSFis61/JkE9rxsjkGRZi14hHr4M=\n - secure: o2nkUQIiABD139XS6L8pxq3XO5gch27hvm/gOdV+dzNKc/s2KomVPWcOyXNxtJGhtecAkABzaW8KHDDi5QL1kNEFx6BxFVMLO8rjFPsMVaBG9Ks6JiDQkkmrGNcnVdxI/6EKTLHTH5WLsz8+J7caDBzvKbEfTux5EamEhxIWgrI=\n```\n\nMore details on Travis encryption at http://about.travis-ci.org/docs/user/encryption-keys/.\n\n#### 3) Hook up publishing\n\nJust put `node-pre-gyp package publish` in your `.travis.yml` after `npm install`.\n\n##### OS X publishing\n\nIf you want binaries for OS X in addition to linux you can enable [multi-os for Travis](http://docs.travis-ci.com/user/multi-os/#Setting-.travis.yml)\n\nUse a configuration like:\n\n```yml\n\nlanguage: cpp\n\nos:\n- linux\n- osx\n\nenv:\n matrix:\n - NODE_VERSION=\"0.10\"\n - NODE_VERSION=\"0.11.14\"\n\nbefore_install:\n- rm -rf ~/.nvm/ && git clone --depth 1 https://github.com/creationix/nvm.git ~/.nvm\n- source ~/.nvm/nvm.sh\n- nvm install $NODE_VERSION\n- nvm use $NODE_VERSION\n```\n\nSee [Travis OS X Gotchas](#travis-os-x-gotchas) for why we replace `language: node_js` and `node_js:` sections with `language: cpp` and a custom matrix.\n\nAlso create platform specific sections for any deps that need install. For example if you need libpng:\n\n```yml\n- if [ $(uname -s) == 'Linux' ]; then apt-get install libpng-dev; fi;\n- if [ $(uname -s) == 'Darwin' ]; then brew install libpng; fi;\n```\n\nFor detailed multi-OS examples see [node-mapnik](https://github.com/mapnik/node-mapnik/blob/master/.travis.yml) and [node-sqlite3](https://github.com/mapbox/node-sqlite3/blob/master/.travis.yml).\n\n##### Travis OS X Gotchas\n\nFirst, unlike the Travis Linux machines, the OS X machines do not put `node-pre-gyp` on PATH by default. To do so you will need to:\n\n```sh\nexport PATH=$(pwd)/node_modules/.bin:${PATH}\n```\n\nSecond, the OS X machines do not support using a matrix for installing different Node.js versions. So you need to bootstrap the installation of Node.js in a cross platform way.\n\nBy doing:\n\n```yml\nenv:\n matrix:\n - NODE_VERSION=\"0.10\"\n - NODE_VERSION=\"0.11.14\"\n\nbefore_install:\n - rm -rf ~/.nvm/ && git clone --depth 1 https://github.com/creationix/nvm.git ~/.nvm\n - source ~/.nvm/nvm.sh\n - nvm install $NODE_VERSION\n - nvm use $NODE_VERSION\n```\n\nYou can easily recreate the previous behavior of this matrix:\n\n```yml\nnode_js:\n - \"0.10\"\n - \"0.11.14\"\n```\n\n#### 4) Publish when you want\n\nYou might wish to publish binaries only on a specific commit. To do this you could borrow from the [Travis CI idea of commit keywords](http://about.travis-ci.org/docs/user/how-to-skip-a-build/) and add special handling for commit messages with `[publish binary]`:\n\n COMMIT_MESSAGE=$(git log --format=%B --no-merges -n 1 | tr -d '\\n')\n if [[ ${COMMIT_MESSAGE} =~ \"[publish binary]\" ]]; then node-pre-gyp publish; fi;\n\nThen you can trigger new binaries to be built like:\n\n git commit -a -m \"[publish binary]\"\n\nOr, if you don't have any changes to make simply run:\n\n git commit --allow-empty -m \"[publish binary]\"\n\nWARNING: if you are working in a pull request and publishing binaries from there then you will want to avoid double publishing when Travis CI builds both the `push` and `pr`. You only want to run the publish on the `push` commit. See https://github.com/Project-OSRM/node-osrm/blob/8eb837abe2e2e30e595093d16e5354bc5c573575/scripts/is_pr_merge.sh which is called from https://github.com/Project-OSRM/node-osrm/blob/8eb837abe2e2e30e595093d16e5354bc5c573575/scripts/publish.sh for an example of how to do this.\n\nRemember this publishing is not the same as `npm publish`. We're just talking about the binary module here and not your entire npm package. To automate the publishing of your entire package to npm on Travis see http://about.travis-ci.org/docs/user/deployment/npm/\n\n# Versioning\n\nThe `binary` properties of `module_path`, `remote_path`, and `package_name` support variable substitution. The strings are evaluated by `node-pre-gyp` depending on your system and any custom build flags you passed.\n\n - `node_abi`: The node C++ `ABI` number. This value is available in Javascript as `process.versions.modules` as of [`>= v0.10.4 >= v0.11.7`](https://github.com/joyent/node/commit/ccabd4a6fa8a6eb79d29bc3bbe9fe2b6531c2d8e) and in C++ as the `NODE_MODULE_VERSION` define much earlier. For versions of Node before this was available we fallback to the V8 major and minor version.\n - `platform` matches node's `process.platform` like `linux`, `darwin`, and `win32` unless the user passed the `--target_platform` option to override.\n - `arch` matches node's `process.arch` like `x64` or `ia32` unless the user passes the `--target_arch` option to override.\n - `configuration` - Either 'Release' or 'Debug' depending on if `--debug` is passed during the build.\n - `module_name` - the `binary.module_name` attribute from `package.json`.\n - `version` - the semver `version` value for your module from `package.json` (NOTE: ignores the `semver.build` property).\n - `major`, `minor`, `patch`, and `prelease` match the individual semver values for your module's `version`\n - `build` - the sevmer `build` value. For example it would be `this.that` if your package.json `version` was `v1.0.0+this.that`\n - `prerelease` - the semver `prerelease` value. For example it would be `alpha.beta` if your package.json `version` was `v1.0.0-alpha.beta`\n\n\nThe options are visible in the code at <https://github.com/mapbox/node-pre-gyp/blob/612b7bca2604508d881e1187614870ba19a7f0c5/lib/util/versioning.js#L114-L127>\n\n# Download binary files from a mirror\n\nS3 is broken in China for the well known reason.\n\nUsing the `npm` config argument: `--{module_name}_binary_host_mirror` can download binary files through a mirror.\n\ne.g.: Install [v8-profiler](https://www.npmjs.com/package/v8-profiler) from `npm`.\n\n```bash\n$ npm install v8-profiler --profiler_binary_host_mirror=https://npm.taobao.org/mirrors/node-inspector/\n```\n",
"readmeFilename": "README.md",
"gitHead": "2c32561503c33728cb8de5a445e76a28868826a8",
"bugs": {

@@ -64,44 +66,5 @@ "url": "https://github.com/mapbox/node-pre-gyp/issues"

"homepage": "https://github.com/mapbox/node-pre-gyp#readme",
"_id": "node-pre-gyp@0.6.30",
"_shasum": "64d3073a6f573003717ccfe30c89023297babba1",
"_from": "node-pre-gyp@>=0.6.28 <0.7.0",
"_npmVersion": "2.15.9",
"_nodeVersion": "4.5.0",
"_npmUser": {
"name": "springmeyer",
"email": "dane@mapbox.com"
},
"dist": {
"shasum": "64d3073a6f573003717ccfe30c89023297babba1",
"tarball": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.30.tgz"
},
"maintainers": [
{
"name": "springmeyer",
"email": "dane@dbsgeo.com"
},
{
"name": "bergwerkgis",
"email": "wb@bergwerk-gis.at"
},
{
"name": "mikemorris",
"email": "michael.patrick.morris@gmail.com"
},
{
"name": "kkaefer",
"email": "kkaefer@gmail.com"
},
{
"name": "yhahn",
"email": "young@developmentseed.org"
}
],
"_npmOperationalInternal": {
"host": "packages-16-east.internal.npmjs.com",
"tmp": "tmp/node-pre-gyp-0.6.30.tgz_1472663592258_0.5457425087224692"
},
"directories": {},
"_resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.30.tgz",
"readme": "ERROR: No README data found!"
"_id": "node-pre-gyp@0.6.31",
"_shasum": "d8a00ddaa301a940615dbcc8caad4024d58f6017",
"_from": "node-pre-gyp@>=0.6.31 <0.7.0"
}

@@ -17,3 +17,3 @@ # node-pre-gyp

- A variety of developer targeted commands for packaging, testing, and publishing binaries.
- A Javascript module that can dynamically require your installed binary: `require('node-pre-gyp').find`
- A JavaScript module that can dynamically require your installed binary: `require('node-pre-gyp').find`

@@ -149,5 +149,5 @@ For a hello world example of a module packaged with `node-pre-gyp` see <https://github.com/springmeyer/node-addon-example> and [the wiki ](https://github.com/mapbox/node-pre-gyp/wiki/Modules-using-node-pre-gyp) for real world examples.

Why then not require S3? Because while some applications using node-pre-gyp need to distribute binaries as large as 20-30 MB, others might have very small binaries and might wish to store them in a github repo. This is not recommended, but if an author really wants to host in a non-s3 location then it should be possible.
Why then not require S3? Because while some applications using node-pre-gyp need to distribute binaries as large as 20-30 MB, others might have very small binaries and might wish to store them in a GitHub repo. This is not recommended, but if an author really wants to host in a non-s3 location then it should be possible.
It should also be mentioned that there is an optional and entirely seperate npm module called [node-pre-gyp-github](https://github.com/bchr02/node-pre-gyp-github) which is intended to complement node-pre-gyp and be installed along with it. It provides the ability to store and publish your binaries within your repositories GitHub Releases if you would rather not use S3 directly. Installation and usage instructions can be found [here](https://github.com/bchr02/node-pre-gyp-github), but the basic premise is that instead of using the ```node-pre-gyp publish``` command you would use ```node-pre-gyp-githib publish```.
It should also be mentioned that there is an optional and entirely separate npm module called [node-pre-gyp-github](https://github.com/bchr02/node-pre-gyp-github) which is intended to complement node-pre-gyp and be installed along with it. It provides the ability to store and publish your binaries within your repositories GitHub Releases if you would rather not use S3 directly. Installation and usage instructions can be found [here](https://github.com/bchr02/node-pre-gyp-github), but the basic premise is that instead of using the ```node-pre-gyp publish``` command you would use ```node-pre-gyp-github publish```.

@@ -376,11 +376,11 @@ ##### The `binary` object has two optional properties

Go to https://ci.appveyor.com/signup/free and sign in with your github account.
Go to https://ci.appveyor.com/signup/free and sign in with your GitHub account.
#### 2) Create a new project
Go to https://ci.appveyor.com/projects/new and select the github repo for your module
Go to https://ci.appveyor.com/projects/new and select the GitHub repo for your module
#### 3) Add appveyor.yml and push it
Once you have committed an `appveyor.yml` ([appveyor.yml reference](http://www.appveyor.com/docs/appveyor-yml)) to your github repo and pushed it appveyor should automatically start building your project.
Once you have committed an `appveyor.yml` ([appveyor.yml reference](http://www.appveyor.com/docs/appveyor-yml)) to your GitHub repo and pushed it AppVeyor should automatically start building your project.

@@ -409,3 +409,3 @@ #### 4) Create secure variables

You might wish to publish binaries only on a specific commit. To do this you could borrow from the [Travis.ci idea of commit keywords](http://about.travis-ci.org/docs/user/how-to-skip-a-build/) and add special handling for commit messages with `[publish binary]`:
You might wish to publish binaries only on a specific commit. To do this you could borrow from the [Travis CI idea of commit keywords](http://about.travis-ci.org/docs/user/how-to-skip-a-build/) and add special handling for commit messages with `[publish binary]`:

@@ -464,3 +464,3 @@ SET CM=%APPVEYOR_REPO_COMMIT_MESSAGE%

If you want binaries for OS X in addition to linux you can enable [multi-os for travis](http://docs.travis-ci.com/user/multi-os/#Setting-.travis.yml)
If you want binaries for OS X in addition to linux you can enable [multi-os for Travis](http://docs.travis-ci.com/user/multi-os/#Setting-.travis.yml)

@@ -489,3 +489,3 @@ Use a configuration like:

See [Travis OS X Gochas](#travis-os-x-gochas) for why we replace `language: node_js` and `node_js:` sections with `language: cpp` and a custom matrix.
See [Travis OS X Gotchas](#travis-os-x-gotchas) for why we replace `language: node_js` and `node_js:` sections with `language: cpp` and a custom matrix.

@@ -501,5 +501,5 @@ Also create platform specific sections for any deps that need install. For example if you need libpng:

##### Travis OS X Gochas
##### Travis OS X Gotchas
First, unlike the Travis linux machines the OS X machines do not put `node-pre-gyp` on PATH by default. So to you will need to:
First, unlike the Travis Linux machines, the OS X machines do not put `node-pre-gyp` on PATH by default. To do so you will need to:

@@ -510,3 +510,3 @@ ```sh

Second, the OS X machines do not support using a matrix for installing different node.js versions. So you need to bootstrap the installation of node.js in a cross platform way.
Second, the OS X machines do not support using a matrix for installing different Node.js versions. So you need to bootstrap the installation of Node.js in a cross platform way.

@@ -538,3 +538,3 @@ By doing:

You might wish to publish binaries only on a specific commit. To do this you could borrow from the [Travis.ci idea of commit keywords](http://about.travis-ci.org/docs/user/how-to-skip-a-build/) and add special handling for commit messages with `[publish binary]`:
You might wish to publish binaries only on a specific commit. To do this you could borrow from the [Travis CI idea of commit keywords](http://about.travis-ci.org/docs/user/how-to-skip-a-build/) and add special handling for commit messages with `[publish binary]`:

@@ -552,3 +552,3 @@ COMMIT_MESSAGE=$(git log --format=%B --no-merges -n 1 | tr -d '\n')

WARNING: if you are working in a pull request and publishing binaries from there then you will want to avoid double publishing when Travis.ci builds both the `push` and `pr`. You only want to run the publish on the `push` commit. See https://github.com/Project-OSRM/node-osrm/blob/8eb837abe2e2e30e595093d16e5354bc5c573575/scripts/is_pr_merge.sh which is called from https://github.com/Project-OSRM/node-osrm/blob/8eb837abe2e2e30e595093d16e5354bc5c573575/scripts/publish.sh for an example of how to do this.
WARNING: if you are working in a pull request and publishing binaries from there then you will want to avoid double publishing when Travis CI builds both the `push` and `pr`. You only want to run the publish on the `push` commit. See https://github.com/Project-OSRM/node-osrm/blob/8eb837abe2e2e30e595093d16e5354bc5c573575/scripts/is_pr_merge.sh which is called from https://github.com/Project-OSRM/node-osrm/blob/8eb837abe2e2e30e595093d16e5354bc5c573575/scripts/publish.sh for an example of how to do this.

@@ -555,0 +555,0 @@ Remember this publishing is not the same as `npm publish`. We're just talking about the binary module here and not your entire npm package. To automate the publishing of your entire package to npm on Travis see http://about.travis-ci.org/docs/user/deployment/npm/

{
"name": "sqlite3",
"description": "Asynchronous, non-blocking SQLite3 bindings",
"version": "3.1.6",
"version": "3.1.7",
"homepage": "http://github.com/mapbox/node-sqlite3",

@@ -40,4 +40,4 @@ "author": {

"dependencies": {
"nan": "~2.3.3",
"node-pre-gyp": "~0.6.28"
"nan": "~2.4.0",
"node-pre-gyp": "~0.6.31"
},

@@ -48,3 +48,3 @@ "bundledDependencies": [

"devDependencies": {
"mocha": "2.x",
"mocha": "3.x",
"aws-sdk": "2.x"

@@ -51,0 +51,0 @@ },

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc