ci: don't run duplicate tests on pull requests

This commit is contained in:
Steven Arcangeli 2022-07-28 08:02:14 -07:00
parent 99a6c531b2
commit 4466fd9836
2 changed files with 32 additions and 32 deletions

View File

@ -1,31 +0,0 @@
name: Lint
on: [push, pull_request]
jobs:
luacheck:
name: Luacheck
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
- name: Prepare
run: |
sudo apt-get update
sudo add-apt-repository universe
sudo apt install luarocks -y
sudo luarocks install luacheck
- name: Run Luacheck
run: luacheck .
stylua:
name: StyLua
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Stylua
uses: JohnnyMorganz/stylua-action@1.0.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --check .

View File

@ -1,8 +1,39 @@
name: Run tests
on: [push, pull_request]
on:
push:
branches:
- master
pull_request: ~
jobs:
luacheck:
name: Luacheck
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
- name: Prepare
run: |
sudo apt-get update
sudo add-apt-repository universe
sudo apt install luarocks -y
sudo luarocks install luacheck
- name: Run Luacheck
run: luacheck .
stylua:
name: StyLua
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Stylua
uses: JohnnyMorganz/stylua-action@1.0.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --check .
run_tests:
strategy:
matrix: