Skip to content

fix: Stickyness of forms #147

fix: Stickyness of forms

fix: Stickyness of forms #147

name: React Lint on PR
on:
pull_request:
paths:
- "apps/dashboard/**"
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: "20.12"
- name: Install pnpm
run: npm install -g [email protected]
- name: Install dependencies
run: cd apps/dashboard && pnpm install
- name: Get list of changed files
id: getfile
run: |
echo "Changed files:"
git fetch origin ${{ github.event.pull_request.base.ref }} # fetch the base branch
files=$(git diff --name-only FETCH_HEAD..HEAD | grep 'apps/dashboard/.*\.\(js\|jsx\|ts\|tsx\)$' | sed 's#apps/dashboard/##')
echo "$files"
echo "FILES=$files" >> $GITHUB_ENV
- name: Run ESLint on changed files
run: cd apps/dashboard && pnpm run ci-eslint-check -- ${{ env.FILES }}
- name: Run Prettier on changed files
run: cd apps/dashboard && pnpm run ci-prettier-check -- ${{ env.FILES }}