diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e5045be..6419981 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,4 +1,3 @@ -# This workflow runs ESLint, Prettier, unit tests, and e2e tests using pnpm. name: CI on: @@ -17,6 +16,8 @@ jobs: uses: actions/setup-node@v3 with: node-version: 20 + - name: Install pnpm + run: npm install -g pnpm - name: Install dependencies run: pnpm install - name: Run Prettier (Pre-commit or in workflow) @@ -30,6 +31,8 @@ jobs: uses: actions/setup-node@v3 with: node-version: 20 + - name: Install pnpm + run: npm install -g pnpm - name: Install dependencies run: pnpm install - name: Run ESLint diff --git a/.github/workflows/validate-pr-title.yml b/.github/workflows/validate-pr-title.yml index 8e89e9b..82f2551 100644 --- a/.github/workflows/validate-pr-title.yml +++ b/.github/workflows/validate-pr-title.yml @@ -1,14 +1,23 @@ -# This workflow validates pull request titles against Commitlint rules. -name: Validate PR Title +name: "Lint PR" on: - pull_request: + pull_request: + types: + - opened + - edited + - synchronize + pull_request_target: + types: + - opened + - edited + - synchronize jobs: - validate-title: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: dreampulse/action-lint-pull-request-title@v3 # Action for title validation - with: - config: '.commitlintrc.js' + lint-pr: + name: Validate PR title + runs-on: ubuntu-latest + steps: + - name: Lint PR + uses: amannn/action-semantic-pull-request@v4.6.0 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/backend/.commitlintrc.js b/backend/.commitlintrc.js deleted file mode 100644 index 3c496d1..0000000 --- a/backend/.commitlintrc.js +++ /dev/null @@ -1,11 +0,0 @@ -module.exports = { - extends: ['@commitlint/config-conventional'], - rules: { - 'type-enum': [ - 2, - 'always', - ['feat', 'fix', 'refactor', 'docs', 'style', 'test', 'build', 'chore'], - ], - 'subject-full-stop': [0, 'never'], - }, -};