hunk.code_window:       fetchLocks: ctx.fetchLocks,
         target,
         resolution,
         loggedPkg,
         got: options.got,
         force: options.force,
       })
       if (fetchingPkg == null) {
         fetchingPkg = fetchingFiles.then(() => requireJson(path.join(target, 'package.json')))
  
hunk.labels: keep keep keep keep add keep keep keep keep keep
hunk.after_edit:       linkLocal: options.linkLocal,
  
hunk.file_path: src/install/fetch.ts
hunk.type: add
file: import RegClient = require('anonymous-npm-registry-client')
  
  export async function add (pkg: string, version: string, distTag: string) {
    const client = new RegClient()
  
    // just to make verdaccio cache the package
    await new Promise((resolve, reject) => client.distTags.fetch('http://localhost:4873', {package: pkg}, (err: Error) => err ? reject(err) : resolve()))
  
    // the tag has to be removed first because in verdaccio it is an array of versions
    await new Promise((resolve, reject) => client.distTags.rm('http://localhost:4873', {package: pkg, distTag}, (err: Error) => err ? reject(err) : resolve()))
    await new Promise((resolve, reject) => client.distTags.add('http://localhost:4873', {package: pkg, version, distTag}, (err: Error) => err ? reject(err) : resolve()))
  }
  