MCPcopy Index your code
hub / github.com/nodejs/node / exec

Method exec

deps/npm/lib/commands/cache.js:96–112  ·  view source on GitHub ↗
(args)

Source from the content-addressed store, hash-verified

94 }
95
96 async exec (args) {
97 const cmd = args.shift()
98 switch (cmd) {
99 case 'rm': case 'clear': case 'clean':
100 return await this.clean(args)
101 case 'add':
102 return await this.add(args)
103 case 'verify': case 'check':
104 return await this.verify()
105 case 'ls':
106 return await this.ls(args)
107 case 'npx':
108 return await this.npx(args)
109 default:
110 throw this.usageError()
111 }
112 }
113
114 // npm cache npx
115 async npx ([cmd, ...keys]) {

Callers

nothing calls this directly

Calls 7

cleanMethod · 0.95
addMethod · 0.95
verifyMethod · 0.95
lsMethod · 0.95
npxMethod · 0.95
usageErrorMethod · 0.80
shiftMethod · 0.45

Tested by

no test coverage detected