Is Lerna pushing packages to different repositories?
See original GitHub issueSorry for the newbie question, but it seems I can’t find the answer to this question. I have a monorepo with Yarn workspaces
and Lerna
/lerna.json
/package.json (with a github repo)
/packages/A
/packages/A/package.json (with a github repo)
/packages/B
/packages/B/package.json (with a github repo)
/packages/C
/packages/C/package.json (with a github repo)
/site
/site/package.json (with a github repo)
Then, my beliefs are that with Lerna
I can develop the site and packages all together with ease, which is done with Yarn workspaces
, and then npm-publish
packages A
, B
and C
and site
separately. I have been able to do this, but, here is what I don’t understand:
Before publishing to npm
, I expected Lerna to push the changes to each github
repository, and to do it without publishing with lerna version
.
But I cannot get this done. Then, is this supposed to work? can I git push
changes of all packages to their respective repositories? Or this is precisely what is not being done in a monorepo?
If I want this, do I need to implement subtrees
or something similar?
Cheers,
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (1 by maintainers)
Top GitHub Comments
@TrejGun I’ve just changed my implementation for a more understandable approach based on https://github.com/johno/actions-push-subdirectories/blob/master/entrypoint.sh and https://github.com/gatsbyjs/gatsby/blob/8933ca9b3bf2c9b4fd580dd437d8695c3be705b7/scripts/clone-and-validate.sh
It that’s of interest for you
@kuworking thanks, i dont need this now but will keep in mind