Browse Source

Disable update-notifier (#609)

* Revert "Only show update notifications when loaded from npm (#606)"

This reverts commit 3ef666ba8d.

* Revert "Brought the update notification back"

This reverts commit 5d3d9d4f37.
master
Matheus Fernandes 8 years ago
committed by Guillermo Rauch
parent
commit
b7a8f23475
  1. 2
      bin/now.js
  2. 9
      lib/pkg.js

2
bin/now.js

@ -26,7 +26,7 @@ try {
// Utilities
const pkg = require('../lib/pkg')
if (pkg._npmPkg) {
if (!process.pkg) {
const notifier = updateNotifier({ pkg })
const update = notifier.update

9
lib/pkg.js

@ -1,13 +1,10 @@
/* eslint-disable import/no-unresolved */
const path = require('path')
const pkg = require('../package.json')
let pkg
try {
const distDir = path.dirname(process.execPath)
pkg._npmPkg = require(path.join(distDir, '../../package.json'))
pkg = require('../package.json')
} catch (err) {
pkg._npmPkg = null
pkg = require('../../package.json')
}
module.exports = pkg

Loading…
Cancel
Save