diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f5c436b..1f49328 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,8 +8,8 @@ permissions: contents: write jobs: - format: - name: format + lint: + name: lint runs-on: ubuntu-latest steps: @@ -23,20 +23,15 @@ jobs: with: node-version: latest - - name: Format - run: | - npx prettier --write . + - name: Install linting tools + run: npm install --no-save eslint @eslint/js typescript typescript-eslint - - name: Commit formatting changes + - name: Lint run: | - git config user.name "github-actions[bot]" - git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - - git add . - git commit -m "chore: apply formatting" || exit 0 - git push - lint: - name: lint + npx eslint --fix . + format: + name: format + needs: lint runs-on: ubuntu-latest steps: @@ -50,15 +45,15 @@ jobs: with: node-version: latest - - name: lint + - name: Format run: | - npx eslint --fix . + npx prettier --write . - - name: Commit linting changes + - name: Commit formatting changes run: | git config user.name "github-actions[bot]" git config user.email "41898282+github-actions[bot]@users.noreply.github.com" git add . - git commit -m "chore: apply linting" || exit 0 + git commit -m "chore: apply formatting" || exit 0 git push diff --git a/eslint.config.mjs b/eslint.config.mjs index b37018e..ff6a098 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -3,9 +3,8 @@ import js from '@eslint/js'; import { defineConfig } from 'eslint/config'; import tseslint from 'typescript-eslint'; -import eslintPrettier from 'eslint-config-prettier'; export default defineConfig({ files: ['src/**/*.{js,ts}'], - extends: [js.configs.recommended, tseslint.configs.recommended, eslintPrettier] + extends: [js.configs.recommended, tseslint.configs.recommended] }); diff --git a/package.json b/package.json index 5809491..7c0af25 100644 --- a/package.json +++ b/package.json @@ -38,7 +38,6 @@ "@eslint/js": "^10.0.1", "@types/node": "^26.1.2", "eslint": "^10.8.1", - "eslint-config-prettier": "^10.1.8", "prettier": "^3.9.6", "prisma": "^7.9.1", "tsup": "^8.5.1",