From 294d3f91b4a19c56e86047522469b0b840232358 Mon Sep 17 00:00:00 2001 From: swve Date: Sun, 15 Oct 2023 13:16:16 +0200 Subject: [PATCH] chore: adapt ci to new structure --- .github/workflows/api-lint.yaml | 18 ++++++++++++++++++ .github/workflows/backend-lint.yaml | 8 -------- .../{frontend-lint.yaml => web-lint.yaml} | 16 ++++++++++++---- 3 files changed, 30 insertions(+), 12 deletions(-) create mode 100644 .github/workflows/api-lint.yaml delete mode 100644 .github/workflows/backend-lint.yaml rename .github/workflows/{frontend-lint.yaml => web-lint.yaml} (55%) diff --git a/.github/workflows/api-lint.yaml b/.github/workflows/api-lint.yaml new file mode 100644 index 00000000..d113f23f --- /dev/null +++ b/.github/workflows/api-lint.yaml @@ -0,0 +1,18 @@ +name: API Lint +on: + push: + paths: + - "apps/api/**" + pull_request: + paths: + - "apps/api/**" +jobs: + ruff: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Ruff lint + uses: chartboost/ruff-action@v1 + with: + src: "./apps/api" diff --git a/.github/workflows/backend-lint.yaml b/.github/workflows/backend-lint.yaml deleted file mode 100644 index 2f495b9b..00000000 --- a/.github/workflows/backend-lint.yaml +++ /dev/null @@ -1,8 +0,0 @@ -name: Backend Lint -on: [ push, pull_request ] -jobs: - ruff: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: chartboost/ruff-action@v1 \ No newline at end of file diff --git a/.github/workflows/frontend-lint.yaml b/.github/workflows/web-lint.yaml similarity index 55% rename from .github/workflows/frontend-lint.yaml rename to .github/workflows/web-lint.yaml index 648c41e8..fb8312eb 100644 --- a/.github/workflows/frontend-lint.yaml +++ b/.github/workflows/web-lint.yaml @@ -1,5 +1,11 @@ -name: Frontend Lint -on: [push, pull_request] +name: Web Lint +on: + push: + paths: + - "apps/web/**" + pull_request: + paths: + - "apps/web/**" jobs: next-lint: runs-on: ubuntu-latest @@ -11,6 +17,8 @@ jobs: with: node-version: 18.x - name: Install dependencies - run: cd front && npm ci + run: npm ci + working-directory: ./apps/web - name: Lint code - run: cd front && npm run lint + run: npm run lint + working-directory: ./apps/web