PATH: //lib/node_modules/npm/lib/commands
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 access.js
↓
X
📄 adduser.js
↓
X
📄 audit.js
↓
X
📄 bin.js
↓
X
📄 birthday.js
↓
X
📄 bugs.js
↓
X
📄 cache.js
↓
X
📄 ci.js
↓
X
📄 completion.js
↓
X
📄 config.js
↓
X
📄 dedupe.js
↓
X
📄 deprecate.js
↓
X
📄 diff.js
↓
X
📄 dist-tag.js
↓
X
📄 docs.js
↓
X
📄 doctor.js
↓
X
📄 edit.js
↓
X
📄 exec.js
↓
X
📄 explain.js
↓
X
📄 explore.js
↓
X
📄 find-dupes.js
↓
X
📄 fund.js
↓
X
📄 get.js
↓
X
📄 help-search.js
↓
X
📄 help.js
↓
X
📄 hook.js
↓
X
📄 init.js
↓
X
📄 install-ci-test.js
↓
X
📄 install-test.js
↓
X
📄 install.js
↓
X
📄 link.js
↓
X
📄 ll.js
↓
X
📄 logout.js
↓
X
📄 ls.js
↓
X
📄 org.js
↓
X
📄 outdated.js
↓
X
📄 owner.js
↓
X
📄 pack.js
↓
X
📄 ping.js
↓
X
📄 pkg.js
↓
X
📄 prefix.js
↓
X
📄 profile.js
↓
X
📄 prune.js
↓
X
📄 publish.js
↓
X
📄 query.js
↓
X
📄 rebuild.js
↓
X
📄 repo.js
↓
X
📄 restart.js
↓
X
📄 root.js
↓
X
📄 run-script.js
↓
X
📄 search.js
↓
X
📄 set-script.js
↓
X
📄 set.js
↓
X
📄 shrinkwrap.js
↓
X
📄 star.js
↓
X
📄 stars.js
↓
X
📄 start.js
↓
X
📄 stop.js
↓
X
📄 team.js
↓
X
📄 test.js
↓
X
📄 token.js
↓
X
📄 uninstall.js
↓
X
📄 unpublish.js
↓
X
📄 unstar.js
↓
X
📄 update.js
↓
X
📄 version.js
↓
X
📄 view.js
↓
X
📄 whoami.js
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: ping.js
const log = require('../utils/log-shim') const pingUtil = require('../utils/ping.js') const BaseCommand = require('../base-command.js') class Ping extends BaseCommand { static description = 'Ping npm registry' static params = ['registry'] static name = 'ping' static ignoreImplicitWorkspace = true async exec (args) { log.notice('PING', this.npm.config.get('registry')) const start = Date.now() const details = await pingUtil({ ...this.npm.flatOptions }) const time = Date.now() - start log.notice('PONG', `${time}ms`) if (this.npm.config.get('json')) { this.npm.output(JSON.stringify({ registry: this.npm.config.get('registry'), time, details, }, null, 2)) } else if (Object.keys(details).length) { log.notice('PONG', `${JSON.stringify(details, null, 2)}`) } } } module.exports = Ping
SIMPAN PERUBAHAN