Skip to content

The open alternative to Salesforce, designed for AI.

Add standard front component ci (#18560)

Raphaël Bosib2f053490d13
diff --git a/.github/workflows/ci-twenty-standard-front-component.yaml b/.github/workflows/ci-twenty-standard-front-component.yaml
new file mode 100644
index 00000000000..cb426fddb07
--- /dev/null
+++ b/.github/workflows/ci-twenty-standard-front-component.yaml
@@ -0,0 +1,66 @@
+name: CI Twenty Standard Front Component
+
+on:
+ pull_request:
+
+permissions:
+ contents: read
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
+
+jobs:
+ changed-files-check:
+ uses: ./.github/workflows/changed-files.yaml
+ with:
+ files: |
+ package.json
+ yarn.lock
+ packages/twenty-standard-application/**
+ packages/twenty-sdk/**
+ packages/twenty-shared/**
+
+ standard-front-component-build-check:
+ needs: changed-files-check
+ if: needs.changed-files-check.outputs.any_changed == 'true'
+ timeout-minutes: 30
+ runs-on: ubuntu-latest
+ steps:
+ - name: Fetch custom Github Actions and base branch history
+ uses: actions/checkout@v4
+ with:
+ fetch-depth: 10
+ - name: Install dependencies
+ uses: ./.github/actions/yarn-install
+ - name: Build twenty-shared
+ run: npx nx build twenty-shared
+ - name: Build twenty-sdk
+ run: npx nx build twenty-sdk
+ - name: Build twenty-standard-application
+ run: npx nx build twenty-standard-application
+ - name: Check for pending standard front component build
+ run: |
+ if ! git diff --quiet -- packages/twenty-standard-application/src/build packages/twenty-standard-application/src/standard-front-component-build-manifest.ts; then
+ echo "::error::Standard front component build output is out of date. Please run 'npx nx build twenty-standard-application' and commit the changes."
+ echo ""
+ echo "The following changes were detected:"
+ echo "==================================================="
+ git diff -- packages/twenty-standard-application/src/build packages/twenty-standard-application/src/standard-front-component-build-manifest.ts
+ echo "==================================================="
+ exit 1
+ fi
+
+ ci-twenty-standard-front-component-status-check:
+ if: always() && !cancelled()
+ timeout-minutes: 5
+ runs-on: ubuntu-latest
+ needs:
+ [
+ changed-files-check,
+ standard-front-component-build-check,
+ ]
+ steps:
+ - name: Fail job if any needs failed
+ if: contains(needs.*.result, 'failure')
+ run: exit 1