diff --git a/.github/workflows/luarocks.yml b/.github/workflows/luarocks.yml new file mode 100644 index 0000000..af847c7 --- /dev/null +++ b/.github/workflows/luarocks.yml @@ -0,0 +1,32 @@ +--- +name: Push to Luarocks + +on: + push: + tags: + - '*' + release: + types: + - created + tags: + - '*' + workflow_dispatch: + pull_request: # Tests the luarocks packaging and installation without publishing + +jobs: + luarocks-upload: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 # Required to count the commits + - name: Get Version + run: echo "LUAROCKS_VERSION=$(git describe --abbrev=0 --tags)" >> $GITHUB_ENV + - name: LuaRocks Upload + uses: nvim-neorocks/luarocks-tag-release@v5 + env: + LUAROCKS_API_KEY: ${{ secrets.LUAROCKS_API_KEY }} + with: + version: ${{ env.LUAROCKS_VERSION }} + dependencies: | + nui.nvim diff --git a/README.md b/README.md index 4edff6a..096a753 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,14 @@ use { } ``` +## For plugin developers + +Consider [publishing your plugin to luarocks](https://github.com/nvim-neorocks/sample-luarocks-plugin), +so that your users don't have to declare dependencies themselves +when installing with a luarocks-compatible plugin manager +like [rocks.nvim](https://github.com/nvim-neorocks/rocks.nvim) +or lazy.nvim extended with [luarocks.nvim](https://github.com/vhyrro/luarocks.nvim). + ## Discord Join [Discord](https://discord.gg/Rj2V3keVS4) to get involved with the community, ask questions, and share tips.