Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
audit: Temporarily suppress git metadata till there's an opt-in
PR-URL: #20389
Credit: @iarna
Reviewed-By: @zkat
  • Loading branch information
iarna authored and zkat committed Apr 20, 2018
1 parent 8c77dde commit be393a290a5207dc75d3d70a32973afb3322306c
Showing with 4 additions and 8 deletions.
  1. +4 −8 lib/install/audit.js
@@ -7,15 +7,11 @@ exports.printInstallReport = printInstallReport
exports.printFullReport = printFullReport

const Bluebird = require('bluebird')
const fs = require('graceful-fs')
const readFile = Bluebird.promisify(fs.readFile)
const auditReport = require('npm-audit-report')
const treeToShrinkwrap = require('../shrinkwrap.js').treeToShrinkwrap
const packageId = require('../utils/package-id.js')
const output = require('../utils/output.js')
const npm = require('../npm.js')
const path = require('path')
const spawn = require('child_process').spawn
const qw = require('qw')
const registryFetch = require('npm-registry-fetch')
const zlib = require('zlib')
@@ -208,9 +204,9 @@ function generateMetadata () {
meta.platform = process.platform
meta.node_env = process.env.NODE_ENV

// TODO strip auth data from git: modules, paths from file:, resolved
// maybe more: top level name/version

return Promise.resolve(meta)
}
/*
const head = path.resolve(npm.prefix, '.git/HEAD')
return readFile(head, 'utf8').then((head) => {
if (!head.match(/^ref: /)) {
@@ -231,7 +227,7 @@ function generateMetadata () {
})
})
}).then(() => meta, () => meta)
}
*/

function generateFromInstall (tree, diffs, install, remove) {
const requires = {}

0 comments on commit be393a2

Please sign in to comment.