Skip to content

Commit

Permalink
Update lint.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
bitpredator committed May 30, 2023
1 parent a6ff937 commit 179fa02
Showing 1 changed file with 32 additions and 15 deletions.
47 changes: 32 additions & 15 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,38 @@
name: Lint
on: [push, pull_request]

on:
pull_request:
branches:
- main

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

permissions:
contents: read

jobs:
lint:
name: Lint Resource
name: Lint
timeout-minutes: 30
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Lint
uses: iLLeniumStudios/fivem-lua-lint-action@v2
with:
capture: "junit.xml"
args: "-t --formatter JUnit"
extra_libs: mysql
- name: Generate Lint Report
if: always()
uses: mikepenz/action-junit-report@v3
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3
- name: Set up Node
uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3
with:
report_paths: "**/junit.xml"
check_name: Linting Report
fail_on_failure: false
node-version: '16'
cache: yarn
- name: Installation
run: yarn
# run: yarn install --immutable # Fails if yarn.lock is modified (unfortunately only works for Yarn 2, and --frozen-lockfile is not the same!)
- name: Check immutable yarn.lock
run: git diff --exit-code
- name: Lint
run: |
echo "::add-matcher::.github/workflows/cspell-problem-matcher.json"
yarn lint:ci
- name: Prettier Code
run: yarn format:diff

0 comments on commit 179fa02

Please sign in to comment.