update main test
This commit is contained in:
parent
10d438d078
commit
78f1b0382f
|
@ -1,17 +1,14 @@
|
||||||
# copied from gbprod/yanky.nvim
|
name: Integration from gbprod/yanky.nvim
|
||||||
name: Integration
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 7 * * 1'
|
- cron: '0 7 * * 1'
|
||||||
# Allows you to run this workflow manually from the Actions tab
|
# Allows you to run this workflow manually from the Actions tab
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
name: Tests
|
name: Tests
|
||||||
|
@ -20,37 +17,32 @@ jobs:
|
||||||
matrix:
|
matrix:
|
||||||
nvim-versions: ['stable', 'nightly']
|
nvim-versions: ['stable', 'nightly']
|
||||||
steps:
|
steps:
|
||||||
- name: Install NeoVim
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
- uses: rhysd/action-setup-vim@v1
|
- uses: rhysd/action-setup-vim@v1
|
||||||
with:
|
with:
|
||||||
neovim: true
|
neovim: true
|
||||||
version: ${{ matrix.nvim-versions }}
|
version: ${{ matrix.nvim-versions }}
|
||||||
- name: Checkout
|
- name: Setup ‘lua’
|
||||||
- uses: actions/checkout@v3
|
uses: leafo/gh-actions-lua@v8
|
||||||
- name: Setup kitckstart and start nvim
|
with:
|
||||||
|
luaVersion: '5.1.5'
|
||||||
|
- name: Setup ‘luarocks’
|
||||||
|
uses: leafo/gh-actions-luarocks@v4
|
||||||
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
ln -sf $GITHUB_WORKSPACE "${XDG_CONFIG_HOME:-$HOME/.config}"/nvim
|
luarocks install luacheck
|
||||||
touch msg.log
|
- name: Run linter
|
||||||
nvim --headless -c ':Lazy! sync' -c ':qa' init.lua 2>&1 | tee -a msg.log
|
run: luacheck init.lua lua/
|
||||||
nvim --headless -c ':checkhealth' -c ':qa' init.lua 2>&1 | tee -a msg.log
|
- name: Run tests
|
||||||
echo -e '\n++++++++++++++++++++++++++++++'
|
run: |
|
||||||
cat msg.log
|
nvim --headless -u init.lua -c ":qa"
|
||||||
echo -e '++++++++++++++++++++++++++++++\n'
|
stylua:
|
||||||
grep -i 'error' msg.log
|
|
||||||
if [ $? -eq 0 ]; then
|
|
||||||
exit 1
|
|
||||||
else
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
stylua-check:
|
|
||||||
name: Check codestyle
|
name: Check codestyle
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code
|
- uses: actions/checkout@v4
|
||||||
uses: actions/checkout@v4
|
- uses: JohnnyMorganz/stylua-action@v3
|
||||||
- name: Stylua Check
|
|
||||||
uses: JohnnyMorganz/stylua-action@v3
|
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
version: latest
|
version: latest
|
||||||
|
|
Loading…
Reference in New Issue