Skip to content

Commit 913fa48

Browse files
committed
Add support for LuaRocks + release workflow
nvim-dap is a common dependency across Neovim plugins. Using luarocks may alleviate the need for users to specify their plugins' dependencies in their plugin manager (e.g., vim-plug or packer). See also [this blog post](https://teto.github.io/posts/2021-09-17-neovim-plugin-luarocks.html) for details. This PR adds a release workflow that publishes this plugin to [LuaRocks](https://luarocks.org/) whenever a tag is pushed, as well as a rockspec that can be used to release to the `dev` channel. For the release workflow to work, someone with a LuaRocks account will have to add their API key to this repo's secrets. Note that I have added a shield to the readme that assumes the existence of an `mfussenegger/nvim-dap` LuaRocks module.
1 parent 0d77088 commit 913fa48

File tree

3 files changed

+67
-0
lines changed

3 files changed

+67
-0
lines changed

.github/workflows/release.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: "release"
2+
on:
3+
push:
4+
tags:
5+
- '*'
6+
jobs:
7+
luarocks-upload:
8+
runs-on: ubuntu-22.04
9+
steps:
10+
- uses: actions/checkout@v3
11+
- name: LuaRocks Upload
12+
uses: nvim-neorocks/[email protected]
13+
env:
14+
LUAROCKS_API_KEY: ${{ secrets.LUAROCKS_API_KEY }}
15+
with:
16+
detailed_description: |
17+
nvim-dap allows you to:
18+
19+
* Launch an application to debug
20+
* Attach to running applications and debug them
21+
* Set breakpoints and step through code
22+
* Inspect the state of the application
23+
copy_directories:
24+
doc
25+
plugin

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212

1313
## Installation
1414

15+
[![LuaRocks](https://img.shields.io/luarocks/v/mfussenegger/nvim-dap?logo=lua&color=purple)](https://luarocks.org/modules/mfussenegger/nvim-dap)
16+
1517
- Install nvim-dap like any other Neovim plugin:
1618
- `git clone https://github.com/mfussenegger/nvim-dap.git ~/.config/nvim/pack/plugins/start/nvim-dap`
1719
- Or with [vim-plug][11]: `Plug 'mfussenegger/nvim-dap'`

nvim-dap-scm-1.rockspec

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
local _MODREV, _SPECREV = 'scm', '-1'
2+
rockspec_format = "3.0"
3+
package = 'nvim-dap'
4+
version = _MODREV .. _SPECREV
5+
6+
description = {
7+
summary = 'Debug Adapter Protocol client implementation for Neovim.',
8+
detailed = [[
9+
nvim-dap allows you to:
10+
11+
* Launch an application to debug
12+
* Attach to running applications and debug them
13+
* Set breakpoints and step through code
14+
* Inspect the state of the application
15+
]],
16+
labels = {
17+
'neovim',
18+
'plugin',
19+
'debug-adapter-protocol',
20+
'debugger',
21+
},
22+
homepage = 'https://github.com/mfussenegger/nvim-dap',
23+
license = 'GPL-3.0',
24+
}
25+
26+
dependencies = {
27+
'lua >= 5.1, < 5.4',
28+
}
29+
30+
source = {
31+
url = 'git://github.com/mfussenegger/nvim-dap',
32+
}
33+
34+
build = {
35+
type = 'builtin',
36+
copy_directories = {
37+
'doc',
38+
'plugin',
39+
},
40+
}

0 commit comments

Comments
 (0)