Skip to content
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

chore: run ci #21

Merged
merged 1 commit into from
May 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .busted
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
return {
_all = {
coverage = false,
lpath = "lua/?.lua;lua/?/init.lua",
},
default = {
verbose = true,
},
tests = {
verbose = true,
},
}
6 changes: 6 additions & 0 deletions .github/workflows/lint.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@ name: Lint and style
on: [push, pull_request]

jobs:
commit_lint:
runs-on: ubuntu-latest
steps:
# Check commit messages
- uses: webiny/[email protected]

stylua:
name: stylua
runs-on: ubuntu-20.04
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: LuaRocks release
on:
push:
tags: # Will upload to luarocks.org when a tag is pushed
- "*"
pull_request: # Will test a local install without uploading to luarocks.org

jobs:
luarocks-release:
runs-on: ubuntu-latest
name: LuaRocks upload
steps:
- name: Checkout
uses: actions/checkout@v3
- name: LuaRocks Upload
uses: nvim-neorocks/luarocks-tag-release@v5
with:
test_interpreters: |
neovim-stable
neovim-nightly
env:
LUAROCKS_API_KEY: ${{ secrets.LUAROCKS_API_KEY }}
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/luarocks
/lua_modules
/.luarocks
/lua
13 changes: 13 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
nvim-test:
git clone https://github.com/lewis6991/nvim-test
nvim-test/bin/nvim-test --init

.PHONY: test
test: nvim-test
NVIM_TEST_VERSION=$(NVIM_TEST_VERSION) \
nvim-test/bin/nvim-test tests \
--lpath=$(PWD)/lua/?.lua \
--verbose \
--filter="$(FILTER)"

-@stty sane
16 changes: 15 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,32 @@ Please follow along with the [initial release discussion](https://github.com/kid

Use your favourite plugin manager to install it. eg:

Using [packer.nvim](https://github.com/wbthomason/packer.nvim)

```lua
use {
'kid-icarus/jira.nvim',
requires = {
'jcdickinson/http.nvim',
}
config = function ()
require'jira'.setup()
require'jira'.setup() -- see configuration section
end
}
```

Using [lazygit.nvim](https://github.com/folke/lazy.nvim)

```lua
{
'kid-icarus/jira.nvim',
dependencies = {
'jcdickinson/http.nvim',
},
opts = {}, -- see configuration section
}
```

## ⚙️ Configuration

First of all, you'll need to create a [personal Jira API
Expand Down
22 changes: 22 additions & 0 deletions jira.nvim-scm-1.rockspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
local _MODREV, _SPECREV = 'scm', '-1'
rockspec_format = '3.0'
package = 'jira.nvim'
version = _MODREV .. _SPECREV

description = {
summary = 'Jira integration for Neovim',
labels = { 'neovim' },
detailed = [[
jira.nvim: interact with Jira from Neovim, using the Jira REST API.
]],
homepage = 'http://github.com/kid-icarus/jira.nvim',
license = 'MIT/X11',
}

dependencies = {
'lua >= 5.1, < 5.4',
}

source = {
url = 'git://github.com/kid-icarus/jira.nvim',
}
1 change: 1 addition & 0 deletions nvim-test
Submodule nvim-test added at 94b485
13 changes: 13 additions & 0 deletions run-tests.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/sh
BUSTED_VERSION="2.1.2-3"

# Install busted if it is not already installed, sometimes you have to run this multiple times
# because busted is trying to use a 5.4 version of lua
if [ ! -d "lua_modules" ]; then
luarocks init
luarocks install busted "$BUSTED_VERSION"
luarocks config --scope project lua_version 5.1
fi
nvim -u NONE \
-c "lua package.path='lua_modules/share/lua/5.1/?.lua;lua_modules/share/lua/5.1/?/init.lua;'..package.path;package.cpath='lua_modules/lib/lua/5.1/?.so;'..package.cpath;local k,l,_=pcall(require,'luarocks.loader') _=k and l.add_context('busted','$BUSTED_VERSION')" \
-l "lua_modules/lib/luarocks/rocks-5.1/busted/$BUSTED_VERSION/bin/busted"
File renamed without changes.
Loading