Skip to content

chore(version): remove sync lock support for npm version below 8.5.0#540

Merged
ghiscoding merged 2 commits intonextfrom
chore/remove-old-npm-sync-workspace
Apr 5, 2023
Merged

chore(version): remove sync lock support for npm version below 8.5.0#540
ghiscoding merged 2 commits intonextfrom
chore/remove-old-npm-sync-workspace

Conversation

@ghiscoding
Copy link
Copy Markdown
Member

Description

Remove support for npm version below 8.5.0 for the --sync-workspace-lock option, the new release will require NPM to be at least 8.5.0 so we can drop old code

Motivation and Context

The code implementation of --sync-workspace-lock for NPM below 8.5.0 was achieved in 2 steps instead of 1 step with NPM >=8.5.0, we had to

  1. run npm shrinkwrap lock, which created the file npm-shrinkwrap.json
  2. then rename npm-shrinkwrap.json back to package-lock.json

but in >=8.5.0 it's achieved in 1 simple step we can simply run npm install --package-lock-only without any shrinkwrap

How Has This Been Tested?

Types of changes

  • Chore (change that has absolutely no effect on users)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 5, 2023

Codecov Report

Merging #540 (f6d75e9) into main (44c80ab) will increase coverage by 0.10%.
The diff coverage is 97.87%.

@@            Coverage Diff             @@
##             main     #540      +/-   ##
==========================================
+ Coverage   97.45%   97.54%   +0.10%     
==========================================
  Files         152      160       +8     
  Lines        4577    12758    +8181     
  Branches     1062     2053     +991     
==========================================
+ Hits         4460    12444    +7984     
- Misses        117      313     +196     
- Partials        0        1       +1     
Impacted Files Coverage Δ
packages/run/src/run-command.ts 89.58% <75.00%> (-10.42%) ⬇️
packages/core/src/utils/defaults.ts 95.73% <76.93%> (+10.01%) ⬆️
packages/core/src/child-process.ts 81.25% <84.62%> (-18.75%) ⬇️
packages/core/src/utils/conf.ts 52.87% <85.72%> (+7.71%) ⬆️
packages/core/src/utils/find-prefix.ts 68.63% <85.72%> (+16.78%) ⬆️
packages/changed/src/changed-command.ts 100.00% <100.00%> (ø)
packages/changed/src/index.ts 100.00% <100.00%> (ø)
packages/cli/src/cli-commands/cli-exec-commands.ts 100.00% <100.00%> (ø)
packages/cli/src/cli-commands/cli-list-commands.ts 100.00% <100.00%> (ø)
...kages/cli/src/cli-commands/cli-publish-commands.ts 100.00% <100.00%> (ø)
... and 99 more

... and 48 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@ghiscoding ghiscoding changed the base branch from main to next April 5, 2023 03:37
@ghiscoding ghiscoding merged commit eb778b1 into next Apr 5, 2023
@ghiscoding ghiscoding deleted the chore/remove-old-npm-sync-workspace branch April 5, 2023 03:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant