socket 0.14.116 → 0.14.118

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -917,7 +917,7 @@ function emitBanner(name) {
917
917
  logger.logger.error(getAsciiHeader(name))
918
918
  }
919
919
  function getAsciiHeader(command) {
920
- const cliVersion = '0.14.116:0dae31b:0be36591:pub' // The '@rollup/plugin-replace' will replace "process.env['INLINED_SOCKET_CLI_VERSION_HASH']".
920
+ const cliVersion = '0.14.118:fb39c6f:81d22cc7:pub' // The '@rollup/plugin-replace' will replace "process.env['INLINED_SOCKET_CLI_VERSION_HASH']".
921
921
  const nodeVersion = process$1.version
922
922
  const apiToken = shadowNpmInject.getDefaultToken()
923
923
  const defaultOrg = shadowNpmInject.getConfigValue('defaultOrg')
@@ -4248,19 +4248,15 @@ async function npmFix(
4248
4248
  spinner?.error(`Reverting ${newSpec}${workspaceDetails}`, error)
4249
4249
  }
4250
4250
  }
4251
- // eslint-disable-next-line no-await-in-loop
4252
- await shadowNpmInject.removeNodeModules(cwd)
4253
- if (isRepo) {
4254
- // eslint-disable-next-line no-await-in-loop
4255
- await gitHardReset(cwd)
4256
- }
4257
4251
  if (saved) {
4258
4252
  editablePkgJson.update(revertData)
4259
- if (!isRepo) {
4260
- // eslint-disable-next-line no-await-in-loop
4261
- await editablePkgJson.save()
4262
- }
4263
4253
  }
4254
+ // eslint-disable-next-line no-await-in-loop
4255
+ await Promise.all([
4256
+ shadowNpmInject.removeNodeModules(cwd),
4257
+ ...(isRepo ? [gitHardReset(cwd)] : []),
4258
+ ...(saved && !isRepo ? [editablePkgJson.save()] : [])
4259
+ ])
4264
4260
  if (!isRepo && installed) {
4265
4261
  // eslint-disable-next-line no-await-in-loop
4266
4262
  await install$1(revertTree, {
@@ -4707,20 +4703,18 @@ async function pnpmFix(
4707
4703
  }
4708
4704
  editablePkgJson.update(revertData)
4709
4705
  // eslint-disable-next-line no-await-in-loop
4710
- await shadowNpmInject.removeNodeModules(cwd)
4711
- if (isRepo) {
4712
- // eslint-disable-next-line no-await-in-loop
4713
- await gitHardReset(cwd)
4714
- // eslint-disable-next-line no-await-in-loop
4715
- actualTree = await getActualTree(cwd)
4716
- } else if (installed) {
4717
- // eslint-disable-next-line no-await-in-loop
4718
- await editablePkgJson.save()
4719
- // eslint-disable-next-line no-await-in-loop
4720
- actualTree = await install(pkgEnvDetails, {
4721
- spinner
4722
- })
4723
- }
4706
+ await Promise.all([
4707
+ shadowNpmInject.removeNodeModules(cwd),
4708
+ ...(isRepo
4709
+ ? [gitHardReset(cwd)]
4710
+ : installed
4711
+ ? [editablePkgJson.save()]
4712
+ : [])
4713
+ ])
4714
+ // eslint-disable-next-line no-await-in-loop
4715
+ actualTree = await install(pkgEnvDetails, {
4716
+ spinner
4717
+ })
4724
4718
  if (errored) {
4725
4719
  if (!failedSpecs.has(newSpecKey)) {
4726
4720
  failedSpecs.add(newSpecKey)
@@ -12302,7 +12296,7 @@ void (async () => {
12302
12296
  await vendor.updater({
12303
12297
  name: SOCKET_CLI_BIN_NAME,
12304
12298
  // The '@rollup/plugin-replace' will replace "process.env['INLINED_SOCKET_CLI_VERSION']".
12305
- version: '0.14.116',
12299
+ version: '0.14.118',
12306
12300
  ttl: 86_400_000 /* 24 hours in milliseconds */
12307
12301
  })
12308
12302
  try {
@@ -12370,5 +12364,5 @@ void (async () => {
12370
12364
  await shadowNpmInject.captureException(e)
12371
12365
  }
12372
12366
  })()
12373
- //# debugId=3e5ae09a-9e97-4ee4-afe7-c5b14260eb95
12367
+ //# debugId=1911c4b4-75fd-408e-81ff-9c4463baa635
12374
12368
  //# sourceMappingURL=cli.js.map