## Problem The plugin requires users to install Node.js and the `live-server` npm package globally. This is a heavyweight external dependency for what amounts to a simple local dev-server workflow, and it creates friction for users who don't otherwise need Node.js. ## Solution Replace the npm shell-out with a pure-Lua HTTP server built on `vim.uv` (libuv bindings), eliminating all external dependencies. The new server supports static file serving, SSE-based live reload, CSS hot-swap without full page reload, directory listings, and recursive file watching with configurable debounce. Minimum Neovim version is bumped to 0.10 for `vim.uv` and `vim.ui.open`. The old `args`-based config is automatically migrated with a deprecation warning. Closes #28.
74 lines
1.8 KiB
YAML
74 lines
1.8 KiB
YAML
name: quality
|
|
|
|
on:
|
|
pull_request:
|
|
branches: [main]
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
changes:
|
|
runs-on: ubuntu-latest
|
|
outputs:
|
|
lua: ${{ steps.changes.outputs.lua }}
|
|
markdown: ${{ steps.changes.outputs.markdown }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: dorny/paths-filter@v3
|
|
id: changes
|
|
with:
|
|
filters: |
|
|
lua:
|
|
- 'lua/**'
|
|
- 'plugin/**'
|
|
- '*.lua'
|
|
- '.luarc.json'
|
|
- '*.toml'
|
|
- 'vim.yaml'
|
|
markdown:
|
|
- '*.md'
|
|
- 'doc/**/*.md'
|
|
|
|
lua-format:
|
|
name: Lua Format Check
|
|
runs-on: ubuntu-latest
|
|
needs: changes
|
|
if: ${{ needs.changes.outputs.lua == 'true' }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: cachix/install-nix-action@v31
|
|
- run: nix develop --command stylua --check .
|
|
|
|
lua-lint:
|
|
name: Lua Lint Check
|
|
runs-on: ubuntu-latest
|
|
needs: changes
|
|
if: ${{ needs.changes.outputs.lua == 'true' }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: cachix/install-nix-action@v31
|
|
- run: nix develop --command selene --display-style quiet .
|
|
|
|
lua-typecheck:
|
|
name: Lua Type Check
|
|
runs-on: ubuntu-latest
|
|
needs: changes
|
|
if: ${{ needs.changes.outputs.lua == 'true' }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Run Lua LS Type Check
|
|
uses: mrcjkb/lua-typecheck-action@v0
|
|
with:
|
|
checklevel: Warning
|
|
directories: lua
|
|
configpath: .luarc.json
|
|
|
|
markdown-format:
|
|
name: Markdown Format Check
|
|
runs-on: ubuntu-latest
|
|
needs: changes
|
|
if: ${{ needs.changes.outputs.markdown == 'true' }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: cachix/install-nix-action@v31
|
|
- run: nix develop --command prettier --check .
|