Skip to content

Conversation

@mrcjkb
Copy link
Contributor

@mrcjkb mrcjkb commented May 13, 2024

Hey 👋

This PR introduces a release-please workflow that automatically opens (or updates) a release PR (which updates a changelog) when a conventional commit is merged into the main branch.

Here's an example of what a release PR looks like:

The nice thing about this workflow is that you get to decide when to merge a release PR.
When doing so, the same workflow creates a release tag and publishes a GitHub release, with the (SemVer) version bump determined from the conventional commit messages.

If you add a personal access token to this repo's secrets (I assumed it to be named PAT in this PR), each release will automatically trigger a luarocks upload. I have modified the workflow file to work nicely with this.

Important

  • If you merge this as is, release-please will compute the version using previous
    conventional commit messages. As there has not been a release yet,
    it will likely start at version 1.0.0. You can change the initial version with a manifest file.
  • Commits that don't comply with the conventional commits spec won't be
    included in release notes. You could enforce this with a GitHub action. Personally, I haven't ever had a need to do so.

- uses: google-github-actions/release-please-action@v4
with:
release-type: simple
token: ${{ secrets.PAT }}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This personal access token would need to be added to this repo's secrets.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how about using default token, secrets.GITHUB_TOKEN

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I won't be touching this PR for now, due to inactivity.
See my last comment.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wsdjeg the reason for not using secrets.GITHUB_TOKEN is that it won't trigger any workflows: https://github.com/googleapis/release-please-action?tab=readme-ov-file#other-actions-on-release-please-prs

The non-default token is required in order for release-please releases to trigger the release workflow that uploads the rockspec to luarocks.org.

@mrcjkb
Copy link
Contributor Author

mrcjkb commented Jun 24, 2024

@hrsh7th no interest in this?

The luarocks package and latest tag being so out of date is a bit of a footgun for luarocks/rocks.nvim users.

@max397574
Copy link
Contributor

The luarocks package and latest tag being so out of date is a bit of a footgun for luarocks/rocks.nvim users.

and this days also lazy.nvim
it could happen that it automatically uses the rockspec with the outdated things

@mrcjkb
Copy link
Contributor Author

mrcjkb commented Jul 25, 2024

Since we haven't received a response, we've removed nvim-cmp 0.0.1 from the luarocks.org root manifest and uploaded a dev one (which installs from scm).

This isn't ideal, because dev rocks can't be pinned to a revision, but at least luarocks/rocks.nvim users can use an up-to-date version of this plugin.

If you ever decide to merge this, please let me know, because we will have to relinquish our rock.

@wsdjeg
Copy link
Collaborator

wsdjeg commented Jan 1, 2026

since this PR will not be updated, so closed.

ref: https://github.com/hrsh7th/nvim-cmp/pull/1923/changes#r2442499195

@wsdjeg wsdjeg closed this Jan 1, 2026
@mrcjkb
Copy link
Contributor Author

mrcjkb commented Jan 1, 2026

@wsdjeg are you taking over maintainership of nvim-cmp?
The reason I stopped updating this PR was because it never got reviewed by @hrsh7th and it seemed like development had ceased.

If development is being picked up again, then I'll be happy to pick this PR up again.

@wsdjeg
Copy link
Collaborator

wsdjeg commented Jan 1, 2026

yeah, I will try to maintain this project.

@mrcjkb
Copy link
Contributor Author

mrcjkb commented Jan 1, 2026

yeah, I will try to maintain this project.

In that case, would you mind reopening this PR for me and marking it as draft?
I'll get back to it soon.

@wsdjeg wsdjeg reopened this Jan 1, 2026
Marc Jakobi and others added 2 commits January 2, 2026 13:25
@mrcjkb
Copy link
Contributor Author

mrcjkb commented Jan 2, 2026

I've rebased this PR. The test failure seems unrelated.
@wsdjeg before merging, please notify me so that I can remove the current nvim-cmp publication from luarocks.org.

@wsdjeg
Copy link
Collaborator

wsdjeg commented Jan 2, 2026

I can merged this PR, BUT I can not create repo's secrets.

@mrcjkb
Copy link
Contributor Author

mrcjkb commented Jan 2, 2026

I can merged this PR, BUT I can not create repo's secrets.

In that case, perhaps we should remove the luarocks upload workflow from this repo (so that this repo only creates automated release PRs) and then add nvim-cmp to NURR, which checks for new releases every 4 hours.
Then we can use the default GITHUB_TOKEN here.

Edit: Done.

Without a custom personal access token, the workflow can't be triggered
by releases created by the release-please workflow.
So instead, the luarocks upload will now be handled by [NURR](https://github.com/lumen-oss/nurr),
which checks for plugin releases every 4 hours.
@wsdjeg
Copy link
Collaborator

wsdjeg commented Jan 2, 2026

Yeah, we can use GITHUB_TOKEN to generate changelogs.md.

@wsdjeg wsdjeg merged commit 85bbfad into hrsh7th:main Jan 2, 2026
1 check failed
mrcjkb added a commit to lumen-oss/nurr that referenced this pull request Jan 2, 2026
mrcjkb added a commit to lumen-oss/nurr that referenced this pull request Jan 2, 2026
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 this pull request may close these issues.

luarocks package very outdated Releases and release automation

3 participants