Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

prebuildify

Package Overview
Dependencies
Maintainers
3
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

prebuildify - npm Package Compare versions

Comparing version 5.0.1 to 6.0.0

6

bin.js

@@ -8,2 +8,3 @@ #!/usr/bin/env node

alias: {
name: 'n',
target: 't',

@@ -21,3 +22,6 @@ version: 'v',

},
boolean: ['quiet', 'strip', 'napi', 'debug', 'all', 'electron-compat']
boolean: ['quiet', 'strip', 'napi', 'debug', 'all', 'electron-compat'],
default: {
napi: true
}
})

@@ -24,0 +28,0 @@

34

index.js

@@ -70,9 +70,12 @@ var proc = require('child_process')

mkdirp(opts.builds, function (err) {
addName(opts, function (err) {
if (err) return cb(err)
loop(opts, function (err) {
mkdirp(opts.builds, function (err) {
if (err) return cb(err)
loop(opts, function (err) {
if (err) return cb(err)
if (opts.artifacts) return copyRecursive(opts.artifacts, opts.builds, cb)
return cb()
if (opts.artifacts) return copyRecursive(opts.artifacts, opts.builds, cb)
return cb()
})
})

@@ -112,8 +115,23 @@ })

function addName (opts, cb) {
if (opts.name) return cb()
fs.readFile(path.join(opts.cwd, 'package.json'), 'utf-8', function (err, pkg) {
if (err) return cb()
try {
opts.name = JSON.parse(pkg).name
} catch (err) {
// do nothing
}
cb()
})
}
function encodeName (name) {
return name.replace(/\//g, '+')
}
function prebuildName (target, opts) {
var tags = [target.runtime]
var tags = [encodeName(opts.name || target.runtime)]
if (opts.napi) {
tags.push('napi')
} else {
if (!opts.napi) {
tags.push('abi' + abi.getAbi(target.target, target.runtime))

@@ -120,0 +138,0 @@ }

{
"name": "prebuildify",
"version": "5.0.1",
"version": "6.0.0",
"description": "Create and package prebuilds for native modules",

@@ -5,0 +5,0 @@ "main": "index.js",

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