Skip to content

feat(dependencies): removed git submodule requirements #8

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

Merged
merged 1 commit into from
Dec 5, 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
5 changes: 2 additions & 3 deletions .github/workflows/.luarc.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@
"diagnostics.libraryFiles": "Disable",
"runtime.version": "LuaJIT",
"workspace.checkThirdParty": "Disable",
"workspace.ignoreDir": [".lua", ".luarocks"],
"workspace.ignoreDir": [".dependencies", ".lua", ".luarocks"],
"workspace.library": [
"$PWD/.dependencies/busted/library",
"$PWD/.dependencies/luassert/library",
"$PWD/.dependencies/luvit-meta/library",
"$VIMRUNTIME/lua",
"lua"
"$VIMRUNTIME/lua"
]
}
26 changes: 20 additions & 6 deletions .github/workflows/llscheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ jobs:

steps:
- uses: actions/checkout@master
with:
submodules: true # Ensure submodules are checked out

- name: Update Submodules
run: git submodule update --init --recursive

- uses: rhysd/action-setup-vim@v1
# NOTE: We need Neovim installed in order to expose the $VIMRUNTIME
Expand Down Expand Up @@ -49,7 +44,26 @@ jobs:
- name: Install llscheck
run: |
luarocks install llscheck
luarocks install nlua

- name: Clone dependencies - busted
uses: actions/checkout@v4
with:
repository: "LuaCATS/busted"
path: ".dependencies/busted"

- name: Clone dependencies - luassert
uses: actions/checkout@v4
with:
repository: "LuaCATS/luassert"
path: ".dependencies/luassert"

- name: Clone dependencies - luavit-meta
uses: actions/checkout@v4
with:
repository: "Bilal2453/luvit-meta"
path: ".dependencies/luvit-meta"

- name: test
run: |
VIMRUNTIME=`nvim -l scripts/print_vimruntime_environment_variable.lua` llscheck --configpath .github/workflows/.luarc.json .
VIMRUNTIME=`nlua -e 'io.write(os.getenv("VIMRUNTIME"))'` llscheck --configpath .github/workflows/.luarc.json .
6 changes: 4 additions & 2 deletions .luarc.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@
"diagnostics.libraryFiles": "Disable",
"runtime.version": "LuaJIT",
"workspace.checkThirdParty": "Disable",
"workspace.ignoreDir": [
".dependencies"
],
"workspace.library": [
"$PWD/.dependencies/busted/library",
"$PWD/.dependencies/luassert/library",
"$PWD/.dependencies/luvit-meta/library",
"$VIMRUNTIME/lua",
"lua"
"$VIMRUNTIME/lua"
]
}
23 changes: 20 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,13 +1,30 @@
.PHONY: api_documentation llscheck luacheck stylua test

llscheck:
VIMRUNTIME=`nvim -l scripts/print_vimruntime_environment_variable.lua` llscheck --configpath .luarc.json .
# Git will error if the repository already exists. We ignore the error.
# NOTE: We still print out that we did the clone to the user so that they know.
#
ifeq ($(OS),Windows_NT)
IGNORE_EXISTING = 2> nul
else
IGNORE_EXISTING = 2> /dev/null || true
endif

clone_git_dependencies:
git clone git@github.com:LuaCATS/busted.git .dependencies/busted $(IGNORE_EXISTING)
git clone git@github.com:LuaCATS/luassert.git .dependencies/luassert $(IGNORE_EXISTING)
git clone git@github.com:Bilal2453/luvit-meta.git .dependencies/luvit-meta $(IGNORE_EXISTING)

api_documentation:
nvim -u scripts/make_api_documentation/minimal_init.lua -l scripts/make_api_documentation/main.lua

llscheck: clone_git_dependencies
VIMRUNTIME=`nlua -e 'io.write(os.getenv("VIMRUNTIME"))'` llscheck --configpath .luarc.json .

luacheck:
luacheck lua plugin scripts spec

stylua:
stylua lua plugin scripts spec

test:
test: clone_git_dependencies
busted --helper spec/minimal_init.lua .
Loading
Loading