Skip to content

Hotfix/uncontrolled lunch tickets #1

Hotfix/uncontrolled lunch tickets

Hotfix/uncontrolled lunch tickets #1

name: React Lint on PR
on:
pull_request:
paths:
- "apps/complete_registration/**"
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: "18.17"
- name: Install pnpm
run: npm install -g pnpm
- name: Install dependencies
run: cd apps/complete_registration && pnpm install
- name: Get list of changed files
id: getfile
run: |
echo "Changed files:"
files=$(git diff --name-only HEAD^ HEAD | grep 'apps/complete_registration/.*\.\(js\|jsx\|ts\|tsx\)$')
echo "$files"
echo "FILES=$files" >> $GITHUB_ENV
- name: Run ESLint on changed files
run: cd apps/complete_registration && pnpm run lint -- ${{ env.FILES }}
- name: Run Prettier on changed files
run: cd apps/complete_registration && pnpm run prettier-check -- ${{ env.FILES }}