tauri/.github/workflows/js-lint.yml
Oscar Dominguez 651fc01492
ci(workflow): add cache to workflows using actions/setup-node (#2740)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2021-10-22 11:33:02 -03:00

54 lines
1.5 KiB
YAML

# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: eslint check
on:
pull_request:
paths:
- ".github/workflows/js-lint.yml"
- "tooling/cli.js/**"
- "tooling/api/**"
- "tooling/create-tauri-app/**"
jobs:
eslint-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "12"
cache: yarn
cache-dependency-path: tooling/*/yarn.lock
- name: install cli.js deps via yarn
working-directory: ./tooling/cli.js/
run: yarn
- name: run cli.js lint
working-directory: ./tooling/cli.js/
run: yarn lint
- name: run cli.js format
working-directory: ./tooling/cli.js/
run: yarn format:check
- name: install api deps via yarn
working-directory: ./tooling/api/
run: yarn
- name: run api lint
working-directory: ./tooling/api/
run: yarn lint
- name: run api format
working-directory: ./tooling/api/
run: yarn format:check
- name: install create-tauri-app deps via yarn
working-directory: ./tooling/create-tauri-app/
run: yarn
- name: run create-tauri-app lint
working-directory: ./tooling/create-tauri-app/
run: yarn lint
- name: run create-tauri-app format
working-directory: ./tooling/create-tauri-app/
run: yarn format:check