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: uninstall.js
const { resolve } = require('path') const Arborist = require('@npmcli/arborist') const rpj = require('read-package-json-fast') const reifyFinish = require('../utils/reify-finish.js') const completion = require('../utils/completion/installed-shallow.js') const ArboristWorkspaceCmd = require('../arborist-cmd.js') class Uninstall extends ArboristWorkspaceCmd { static description = 'Remove a package' static name = 'uninstall' static params = ['save', ...super.params] static usage = ['[<@scope>/]<pkg>...'] static ignoreImplicitWorkspace = false // TODO /* istanbul ignore next */ async completion (opts) { return completion(this.npm, opts) } async exec (args) { // the /path/to/node_modules/.. const path = this.npm.global ? resolve(this.npm.globalDir, '..') : this.npm.localPrefix if (!args.length) { if (!this.npm.global) { throw new Error('Must provide a package name to remove') } else { let pkg try { pkg = await rpj(resolve(this.npm.localPrefix, 'package.json')) } catch (er) { if (er.code !== 'ENOENT' && er.code !== 'ENOTDIR') { throw er } else { throw this.usageError() } } args.push(pkg.name) } } const opts = { ...this.npm.flatOptions, path, rm: args, workspaces: this.workspaceNames, } const arb = new Arborist(opts) await arb.reify(opts) await reifyFinish(this.npm, arb) } } module.exports = Uninstall
SIMPAN PERUBAHAN