refactor: switch to vim api for file and path manipulation #33
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [push, pull_request] | |
jobs: | |
tests: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, windows-latest, macos-latest] | |
nvim_version: ["stable", "nightly"] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Neovim | |
uses: rhysd/action-setup-vim@v1 | |
with: | |
neovim: true | |
version: ${{ matrix.nvim_version }} | |
- name: Run Tests | |
shell: bash | |
run: | | |
nvim --version | |
[ ! -d tests ] && exit 0 | |
make test | |
docs: | |
runs-on: ubuntu-latest | |
if: ${{ github.ref == 'refs/heads/main' }} | |
steps: | |
- uses: actions/checkout@v2 | |
- name: panvimdoc | |
uses: kdheepak/panvimdoc@main | |
with: | |
vimdoc: img-clip.nvim | |
demojify: true | |
treesitter: true | |
- name: Push changes | |
uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
commit_message: "chore(build): auto-generate vimdoc" | |
commit_user_name: "github-actions[bot]" | |
commit_user_email: "github-actions[bot]@users.noreply.github.com" | |
commit_author: "github-actions[bot] <github-actions[bot]@users.noreply.github.com>" | |
luacheck: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Luacheck linter | |
uses: lunarmodules/luacheck@v1 | |
with: | |
args: lua/ | |
stylua: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: JohnnyMorganz/stylua-action@v3 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
version: latest | |
args: --color always --check lua/ |