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

Running bump in monorepo using pnpm clears node_modules #955

Open
kjellknapen opened this issue Mar 14, 2024 · 2 comments
Open

Running bump in monorepo using pnpm clears node_modules #955

kjellknapen opened this issue Mar 14, 2024 · 2 comments

Comments

@kjellknapen
Copy link
Contributor

When using the bump or publish command my node_modules (of the root workspace) are always cleared since the changes in #942.

When running the same command pnpm install --lockfile-only --ignore-scripts in my terminal if the package versions have been bumped, the node_modules are not removed.

I have checked the codebase of execa (package used to call pnpm) and in the pnpm codebase. But I can't seem to find any reason why it deletes the node_modules when running through beachball and why they are not deleted when running the pnpm command myself.

@ecraig12345
Copy link
Member

If you run pnpm in a subdirectory, does that clear the root node_modules? I'm wondering if the issue is that beachball is running pnpm in the wrong directory.

@kjellknapen
Copy link
Contributor Author

No it doesn't clear the node_modules then either. It's a weird bug. I don't even know if it's a beachball or pnpm issue or maybe a combination where beachball enables a certain config or option in pnpm forcing the "recreation" of the node_modules

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

No branches or pull requests

2 participants