Update twenty-front commands (#4667)
# This PR - Moves dev and ci scripts to the `project.json` file in the twenty-front package - Adds a project.json file in the root of the project with the main start command that start both twenty-server and twenty-front applications concurrently - Updates the script command of the root project with the start:prod command (replacing the start command which will be used in dev with the help of nx) - Add a start:prod command in the twenty-front app, replacing the start command (now used for dev purpose) Issue ref #4645 @charlesBochet @FelixMalfait please let me know how can I improve it --------- Co-authored-by: Thaïs Guigon <guigon.thais@gmail.com>
This commit is contained in:
committed by
GitHub
parent
977927af04
commit
627a6bda29
26
.github/workflows/ci-front.yaml
vendored
26
.github/workflows/ci-front.yaml
vendored
@ -74,13 +74,11 @@ jobs:
|
||||
restore-keys: root-node_modules-
|
||||
- name: Install Playwright
|
||||
run: cd packages/twenty-front && npx playwright install
|
||||
- name: Build Storybook
|
||||
run: yarn nx storybook:pages:build twenty-front --quiet
|
||||
- name: Run storybook tests
|
||||
run: |
|
||||
cd packages/twenty-front && npx concurrently -k -s first -n "SB,TEST" -c "magenta,blue" \
|
||||
"npx http-server storybook-static --silent --port 6006" \
|
||||
"yarn storybook:pages:coverage"
|
||||
npx concurrently -k -s first -n "SB,TEST" -c "magenta,blue" \
|
||||
"STORYBOOK_SCOPE=pages npx nx run twenty-front:storybook:static" \
|
||||
"npx wait-on tcp:6006 && STORYBOOK_SCOPE=pages npx nx run twenty-front:storybook:test"
|
||||
front-modules-sb-test:
|
||||
needs: front-yarn-install
|
||||
runs-on: ci-4-cores
|
||||
@ -114,13 +112,11 @@ jobs:
|
||||
restore-keys: root-node_modules-
|
||||
- name: Install Playwright
|
||||
run: cd packages/twenty-front && npx playwright install
|
||||
- name: Build Storybook
|
||||
run: yarn nx storybook:modules:build twenty-front --quiet
|
||||
- name: Run storybook tests
|
||||
run: |
|
||||
cd packages/twenty-front && npx concurrently -k -s first -n "SB,TEST" -c "magenta,blue" \
|
||||
"npx http-server storybook-static --silent --port 6006" \
|
||||
"yarn storybook:modules:coverage"
|
||||
npx concurrently -k -s first -n "SB,TEST" -c "magenta,blue" \
|
||||
"STORYBOOK_SCOPE=modules npx nx run twenty-front:storybook:static" \
|
||||
"npx wait-on tcp:6006 && STORYBOOK_SCOPE=modules npx nx run twenty-front:storybook:test"
|
||||
front-lint-tsc:
|
||||
needs: front-yarn-install
|
||||
runs-on: ubuntu-latest
|
||||
@ -149,13 +145,13 @@ jobs:
|
||||
key: root-node_modules-${{hashFiles('yarn.lock')}}
|
||||
restore-keys: root-node_modules-
|
||||
- name: UI / Run linter
|
||||
run: yarn nx lint twenty-ui
|
||||
run: npx nx lint twenty-ui
|
||||
- name: UI / Run Typescript Check
|
||||
run: yarn nx typecheck twenty-ui
|
||||
run: npx nx run twenty-ui:typecheck:ci
|
||||
- name: Front / Run linter
|
||||
run: yarn nx lint:ci twenty-front
|
||||
run: npx nx run twenty-front:lint:ci
|
||||
- name: Front / Run Typescript Check
|
||||
run: yarn nx tsc:ci twenty-front
|
||||
run: npx nx run twenty-front:typecheck:ci
|
||||
front-jest:
|
||||
needs: front-yarn-install
|
||||
runs-on: ubuntu-latest
|
||||
@ -184,4 +180,4 @@ jobs:
|
||||
key: root-node_modules-${{hashFiles('yarn.lock')}}
|
||||
restore-keys: root-node_modules-
|
||||
- name: Front / Run jest
|
||||
run: yarn nx coverage twenty-front
|
||||
run: npx nx test twenty-front --configuration=ci
|
||||
|
||||
Reference in New Issue
Block a user