pnpm version: 6.17.2
Code to reproduce the issue:
As mentioned in #3901, running pnpm up changes dependencies which the workspace: protocol with a relative path to a version specifier instead:
- "@my-company-scope/package": "workspace:../path/to/package"
+ "@my-company-scope/package": "workspace:^1.0.0"
The link: in the pnpm-lock.yaml file also gets changed - this is a significant problem if the workspace: path was being used to point at a publish directory (again, discussed in #3901):
- '@my-company-scope/package': link:../../packages/package/dist
+ '@my-company-scope/package': link:../../packages/package
Expected behavior:
- The
workspace: specifier is not modified by pnpm up
- The associated
link: in pnpm-lock.yaml is also not modified
Actual behavior:
workspace: path specifier is replaced with current package version using ^ range specifier
link: in the pnpm-lock.yaml file is overwritten
- Note that the
link: still gets modified even when running up with the --no-save flag
Additional information:
node -v prints: v14.15.1
- Windows, macOS, or Linux?: Linux
pnpm version: 6.17.2
Code to reproduce the issue:
As mentioned in #3901, running
pnpm upchanges dependencies which theworkspace:protocol with a relative path to a version specifier instead:The
link:in thepnpm-lock.yamlfile also gets changed - this is a significant problem if theworkspace:path was being used to point at a publish directory (again, discussed in #3901):Expected behavior:
workspace:specifier is not modified bypnpm uplink:inpnpm-lock.yamlis also not modifiedActual behavior:
workspace:path specifier is replaced with current package version using^range specifierlink:in thepnpm-lock.yamlfile is overwrittenlink:still gets modified even when runningupwith the--no-saveflagAdditional information:
node -vprints: v14.15.1