You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, we use lerna for more than NPM packages to align our release workflow. This works very well but can be quite confusing when a package.json file is inside a Go project.
Suggested solution
It would be great, if lerna would support other languages or support a more neutral way to version software. For example a yaml file with the following content could work.
release.yml
name: 'my-app'
version: '0.0.1'
hooks:
postVersion: "gh wf run ${name}" # Trigger a GH workflow
This will be handled as a private package without publishing it to NPM. Git tags, Github releases, changelog aren't NPM specific. Based on the published tag, we can trigger the deployment. Because of the limits described in #701 we would need a way to define a hook that is executed after a release.
Alternative
Create a package.json with the propertly private:true and use scripts to hook into the release lifecycle.
I'd understand if this is not the purpose of the project but I see lerna as much more than just a handy tool for npm packages.
hmm yeah this is not really the purpose of the project and is out of my league, my main goal was really to keep it updated and add a few small features but not necessary large features. I would be glad to receive PR on the subject. I have already invested a lot of time on the project already
we would need a way to define a hook that is executed after a release.
can't you just use the postpublish lifecycle script? See Lifecycle Scripts
At this point I think that the answer to this issue should be the same answer as this Lerna issue
Lerna is built on top of npm CLI internals and even when using pnpm as the package manager, it is still npm interals logic that is used for versioning and publishing. We wouldn't look to deviate from npm's way of doing things (i.e. no support for custom manifest files) as that would introduce unnecessary complexity.
I understand your reason for wanting this, but I'm afraid it's not something we will proceed with
Makes sense. I understand if you don't intend to change the scope of the project. I can only speak from my experience. We love Lerna because it helps manage all our packages. As with any monorepo, we work with more than JS/NPM, but all of them have something in common: we separate them into directories and want to version and release them through Git. Lerna isn't so far from being a tool that is specialized in NPM but also helps with a broader problem.
Identify project configuration (Currently, through package.json)
Bumps the version based on conventional-commits
Generate the changelog
Creates a github release
Create a tag
Publishing to NPM is just an intermediate step here.
Haven't see any tool that solve all of these problems in a nice way.
Clear and concise description of the problem
Hello, we use lerna for more than NPM packages to align our release workflow. This works very well but can be quite confusing when a package.json file is inside a Go project.
Suggested solution
It would be great, if lerna would support other languages or support a more neutral way to version software. For example a yaml file with the following content could work.
release.yml
This will be handled as a private package without publishing it to NPM. Git tags, Github releases, changelog aren't NPM specific. Based on the published tag, we can trigger the deployment. Because of the limits described in #701 we would need a way to define a hook that is executed after a release.
Alternative
Create a package.json with the propertly
private:true
and use scripts to hook into the release lifecycle.I'd understand if this is not the purpose of the project but I see lerna as much more than just a handy tool for npm packages.
Additional context
We use lerna in a monorepo with a diverse technology stack https://github.com/wundergraph/cosmo
Validations
The text was updated successfully, but these errors were encountered: