Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change links architecture #21

Closed
GiladShoham opened this issue Jul 27, 2021 · 0 comments · Fixed by #88
Closed

change links architecture #21

GiladShoham opened this issue Jul 27, 2021 · 0 comments · Fixed by #88
Assignees

Comments

@GiladShoham
Copy link
Member

GiladShoham commented Jul 27, 2021

At the moment when doing bvm link we create something like this
{linkName} -> {bvmFolder}/versions/{versionNumber}
for example:
bit -> ~/.bvm/versions/0.0.466
That means then if you install a new version of bit and remove the old one, the folder {bvmFolder}/versions/{versionNumber} doesn't exist anymore.
We do however have references to this folder - the links from any workspace to the core aspects looks like this:
node_modules/@teambit/{coreAspect} -> {bvmFolder}/versions/node_modules/@teambit/{coreAspect} which of course won't exist anymore, so you have to re-link everything.

Instead, it will be better to have a structure like this:
{linkName} -> {bvmFolder}/links/{linkName} -> {bvmFolder}/versions/{versionNumber}
for example:
node_modules/@teambit/{coreAspect} -> {bvmFolder}/links/{linkName}/@teambit/{coreAspect} -> {bvmFolder}/versions/node_modules/@teambit/{coreAspect}

Which means when installing a new version of bit and re-link we will only re-link this part:
before:
{bvmFolder}/links/{linkName} -> {bvmFolder}/versions/{versionNumber}
after (see the newVersionNumber):
{bvmFolder}/links/{linkName} -> {bvmFolder}/versions/{newVersionNumber}

This means no links will be breaking.

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 a pull request may close this issue.

2 participants