-
Notifications
You must be signed in to change notification settings - Fork 150
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
Luarocks tag release #640
Luarocks tag release #640
Conversation
ed61b16
to
df566ac
Compare
Ty @mrcjkb! There was already an accepted PR that added a rockspec by @teto, see #521. As for the workflow I’m not sure how that’s going to work as I don’t plan on cadence releases, tags or semver, I make sure nothing breaks and release main, while I do think such workflows are valuable for certain plugins I don’t see any benefit of changing the way fzf-lua is released, it’s been very stable and aside from the occasional feature request / minor bug there aren’t many new changes. That said, is there any value in a luarocks publishing workflow given updates are just a git push to the main branch? |
Ah, thanks for the info. That makes the rockspec I added redundant :) To answer your question: The Neotest has a similar worfflow to you. using the semantic-release plugin to automatically publish a new release whenever a PR is merged into |
Ty for this info @mrcjkb, the issue is I’d like to avoid “releases” altogether, the way I view this plug-in is merely a bunch of scripts that call |
The workflow doesn't require PRs or branches. It can be configured to trigger on any push to the main branch. But if you don't want tags to be generated on every commit, I could look into updating the |
I'd rather not, either I make the tags myself properly or it's just another commit hash with less felxibility if I make a quick rebase fix. |
Then I can look into adding support for untagged releases (with incrementing dummy versions for luarocks) to the workflow (if you would be open to that). on:
workflow_dispatch: # allows manual triggering
schedule:
- cron: '0 0 * * 0' # runs weekly on Sunday at 00:00 It would be great to have |
That would be great if we can get luarocks publishing while not changing anything in the current workflow! |
5e4bbc7
to
5b11715
Compare
4e26f5b
to
8ecc677
Compare
Done 😄 |
Amazing work, tysm @mrcjkb! Gonna do some testing on my end and see to it that I understand it all and merge. |
Tysm @mrcjkb for this amazing addition! Now we have to wait for the workflow to do it's thing :-) |
Glad to contribute 😄 |
Just realized the merge missed midnight UTC by a few minutes lol We’ll see what happens tomorrow, I added the |
It can also be triggered manually :) |
TIL :) Success! |
that's awesome thnaks ! I will update nixpkgs with all those new tagged releases this week ! |
Hi @mrcjkb, would you help me find the issue why the workflow failed? I’ve changed the names to |
For some reason, it failed to fetch the license info via the GitHub API. Maybe the request timed out? with:
license: "AGPL-3.0" |
which task should have the |
That would be the upload task - name: LuaRocks Upload
uses: nvim-neorocks/luarocks-tag-release@v2.1.0
if: ${{ env.NEW_COMMIT_COUNT > 0 }}
env:
LUAROCKS_API_KEY: ${{ secrets.LUAROCKS_API_KEY }}
with:
version: ${{ env.LUAROCKS_VERSION }}
copy_directories: |
doc
plugin
license: "AGPL-3.0" |
Worked great, ty @mrcjkb! https://github.com/ibhagwan/fzf-lua/actions/runs/4225732245/jobs/7338373443 |
fzf-lua
is a common dependency across Neovim plugins (see for example gennaro-tedesco/nvim-possession#19). Using luarocks may alleviate the need for users to specify their plugins' dependencies in their plugin manager (e.g., vim-plug or packer).See this blog post for more details.
This PR adds a release workflow that publishes this plugin to LuaRocks whenever a tag is pushed, as well as a rockspec that can be used to release to the
dev
channel or install this plugin from source using the luarocks CLI.For the release workflow to work, someone with a LuaRocks account will have to add their API key to this repository's secrets.
Note that I have added a shield to the readme that assumes the existence of an
ibhagwan/fzf-lua
LuaRocks module.