From 3417897c372d914a7f6e87507afa9469c05ea4c6 Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 15:13:07 +0200 Subject: [PATCH 1/7] chore(CI): boost using turbo --- .gitignore | 1 + package.json | 10 +++++++--- turbo.json | 31 +++++++++++++++++++++++++++++++ yarn.lock | 42 ++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 81 insertions(+), 3 deletions(-) create mode 100644 turbo.json diff --git a/.gitignore b/.gitignore index ed9f9e57949..b9fd53ac34e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,7 @@ /.static # Log files # *.log +.turbo # Mac OS index files # .DS_Store diff --git a/package.json b/package.json index 833a50db4fd..5a861b4d2b1 100644 --- a/package.json +++ b/package.json @@ -13,18 +13,22 @@ "lint-staged": "^15.5.2", "prettier": "^3.6.2", "rimraf": "^5.0.10", + "turbo": "2.5.5", "typescript": "^5.8.3" }, + "packageManager": "yarn@1.22.22", "scripts": { - "postinstall": "talend-yarn-workspace run build:lib && talend-yarn-workspace run build:lib:esm", - "pre-release": "talend-yarn-workspace run pre-release", + "postinstall": "yarn build:lib && yarn build:lib:esm", + "build:lib": "turbo run build:lib", + "build:lib:esm": "turbo run build:lib:esm", + "pre-release": "turbo run pre-release", "start": "yarn workspace @talend/ui-playground run start", "start-storybook": "yarn workspace @talend/ui-storybook-one run start", "release": "yarn pre-release && yarn changeset publish", "lint-staged": "lint-staged", "lint": "cross-env WORKSPACE_RUN_FAIL=no-bail talend-yarn-workspace run lint", "lint-merge-report": "talend-scripts lint-merge-report", - "test": "cross-env TZ=UTC talend-yarn-workspace run test --silent", + "test": "cross-env TZ=UTC turbo run test", "test:update": "cross-env TZ=UTC talend-yarn-workspace run test --silent -u", "test:cov": "cross-env TZ=UTC talend-yarn-workspace run test:cov", "test:demo": "talend-yarn-workspace run test:demo", diff --git a/turbo.json b/turbo.json new file mode 100644 index 00000000000..b49088b56db --- /dev/null +++ b/turbo.json @@ -0,0 +1,31 @@ +{ + "$schema": "https://turbo.build/schema.json", + "tasks": { + "build:lib": { + "dependsOn": ["^build:lib"], + "outputs": ["lib/**"] + }, + "build:lib:esm": { + "dependsOn": ["^build:lib:esm"], + "outputs": ["lib-esm/**"] + }, + "pre-release": { + "dependsOn": ["^pre-release"], + "outputs": ["dist"] + }, + "start": {}, + "storybook:build": { + "dependsOn": ["^storybook:build"], + "outputs": ["storybook-static/**"] + }, + "lint": {}, + "check-types": {}, + "test": { + "dependsOn": ["^test"], + "outputs": ["coverage/**", "**/*.snap"] + }, + "test:update": {}, + "format:write": {}, + "format:check": {} + } +} diff --git a/yarn.lock b/yarn.lock index 33865df0ae5..2a12a10e29d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -19385,6 +19385,48 @@ tunnel-agent@^0.6.0: dependencies: safe-buffer "^5.0.1" +turbo-darwin-64@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo-darwin-64/-/turbo-darwin-64-2.5.5.tgz#96a9f4f0acd61e48685c5be1765fa3a0c9be120d" + integrity sha512-RYnTz49u4F5tDD2SUwwtlynABNBAfbyT2uU/brJcyh5k6lDLyNfYKdKmqd3K2ls4AaiALWrFKVSBsiVwhdFNzQ== + +turbo-darwin-arm64@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo-darwin-arm64/-/turbo-darwin-arm64-2.5.5.tgz#2d8e47e1b04d2cb339455adb64fb52c94e587a44" + integrity sha512-Tk+ZeSNdBobZiMw9aFypQt0DlLsWSFWu1ymqsAdJLuPoAH05qCfYtRxE1pJuYHcJB5pqI+/HOxtJoQ40726Btw== + +turbo-linux-64@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo-linux-64/-/turbo-linux-64-2.5.5.tgz#3f8512243d9fa0927d677235d720c07540bf66e8" + integrity sha512-2/XvMGykD7VgsvWesZZYIIVXMlgBcQy+ZAryjugoTcvJv8TZzSU/B1nShcA7IAjZ0q7OsZ45uP2cOb8EgKT30w== + +turbo-linux-arm64@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo-linux-arm64/-/turbo-linux-arm64-2.5.5.tgz#705dc5fdaed6b2c8cc9cd35bbd154ed16e4a78d3" + integrity sha512-DW+8CjCjybu0d7TFm9dovTTVg1VRnlkZ1rceO4zqsaLrit3DgHnN4to4uwyuf9s2V/BwS3IYcRy+HG9BL596Iw== + +turbo-windows-64@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo-windows-64/-/turbo-windows-64-2.5.5.tgz#70c7937e59d1a48391c4ed300b28d0e58ea22073" + integrity sha512-q5p1BOy8ChtSZfULuF1BhFMYIx6bevXu4fJ+TE/hyNfyHJIfjl90Z6jWdqAlyaFLmn99X/uw+7d6T/Y/dr5JwQ== + +turbo-windows-arm64@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo-windows-arm64/-/turbo-windows-arm64-2.5.5.tgz#0ab29d38fcc67ba38652f1cd273df49177cb55b8" + integrity sha512-AXbF1KmpHUq3PKQwddMGoKMYhHsy5t1YBQO8HZ04HLMR0rWv9adYlQ8kaeQJTko1Ay1anOBFTqaxfVOOsu7+1Q== + +turbo@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/turbo/-/turbo-2.5.5.tgz#6057f87c1262acdfa30cf16d4cf74629623f36c9" + integrity sha512-eZ7wI6KjtT1eBqCnh2JPXWNUAxtoxxfi6VdBdZFvil0ychCOTxbm7YLRBi1JSt7U3c+u3CLxpoPxLdvr/Npr3A== + optionalDependencies: + turbo-darwin-64 "2.5.5" + turbo-darwin-arm64 "2.5.5" + turbo-linux-64 "2.5.5" + turbo-linux-arm64 "2.5.5" + turbo-windows-64 "2.5.5" + turbo-windows-arm64 "2.5.5" + tv4@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/tv4/-/tv4-1.3.0.tgz#d020c846fadd50c855abb25ebaecc68fc10f7963" From be314aac6413c97a4b9e41b55b3c74a9db66d62d Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 15:20:30 +0200 Subject: [PATCH 2/7] chore: update test coverage --- .github/workflows/pr-test.yml | 12 +++++++++++- fork/bootstrap-sass/package.json | 3 +-- package.json | 2 +- packages/assets-api/package.json | 2 +- packages/cmf-cqrs/package.json | 2 +- packages/cmf-router/package.json | 2 +- packages/cmf/package.json | 2 +- packages/components/package.json | 2 +- packages/containers/package.json | 2 +- packages/dataviz/package.json | 2 +- packages/faceted-search-query-client/package.json | 2 +- packages/faceted-search/package.json | 2 +- packages/forms/package.json | 2 +- packages/icons/package.json | 1 - packages/sagas/package.json | 2 +- packages/stepper/package.json | 2 +- packages/theme/package.json | 1 - packages/utils/package.json | 2 +- turbo.json | 4 ++-- 19 files changed, 28 insertions(+), 21 deletions(-) diff --git a/.github/workflows/pr-test.yml b/.github/workflows/pr-test.yml index df6cdd801f9..0427ea3a23a 100644 --- a/.github/workflows/pr-test.yml +++ b/.github/workflows/pr-test.yml @@ -26,11 +26,21 @@ jobs: - name: Use Node.js uses: ./.github/actions/setup-node + - name: Cache Turbo + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 + with: + path: .turbo + key: turbo-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}-${{ hashFiles('turbo.json') }} + restore-keys: | + turbo-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}-${{ hashFiles('turbo.json') }} + + - name: Install run: yarn install --frozen-lockfile + - name: Test - run: yarn test --coverage --coverageReporters json-summary + run: yarn test:cov - name: Jest Coverage Comment uses: MishaKav/jest-coverage-comment@d74238813c33e6ea20530ff91b5ea37953d11c91 #1.0.27 diff --git a/fork/bootstrap-sass/package.json b/fork/bootstrap-sass/package.json index 9ca56ec74f6..73b077efa5a 100644 --- a/fork/bootstrap-sass/package.json +++ b/fork/bootstrap-sass/package.json @@ -8,8 +8,7 @@ "scripts": { "build": "echo nothing to build in bootsrap-sass", "test": "echo nothing to test in bootsrap-sass", - "test:update": "echo nothing to test in bootsrap-sass", - "test:cov": "echo nothing to test in bootsrap-sass" + "test:update": "echo nothing to test in bootsrap-sass" }, "files": [ "assets", diff --git a/package.json b/package.json index 5a861b4d2b1..99f80307df7 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ "lint-merge-report": "talend-scripts lint-merge-report", "test": "cross-env TZ=UTC turbo run test", "test:update": "cross-env TZ=UTC talend-yarn-workspace run test --silent -u", - "test:cov": "cross-env TZ=UTC talend-yarn-workspace run test:cov", + "test:cov": "cross-env TZ=UTC turbo run test:cov", "test:demo": "talend-yarn-workspace run test:demo", "test:cron": "talend-yarn-workspace run test:cron", "start-components": "yarn workspace @talend/react-components run start", diff --git a/packages/assets-api/package.json b/packages/assets-api/package.json index 2f6bc17b63a..ed01286a7da 100644 --- a/packages/assets-api/package.json +++ b/packages/assets-api/package.json @@ -18,7 +18,7 @@ "start": "echo nothing to start", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint" }, "keywords": [ diff --git a/packages/cmf-cqrs/package.json b/packages/cmf-cqrs/package.json index 213ac6d32d8..e4699b5a2f2 100644 --- a/packages/cmf-cqrs/package.json +++ b/packages/cmf-cqrs/package.json @@ -12,7 +12,7 @@ "start": "echo nothing to start", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint" }, "repository": { diff --git a/packages/cmf-router/package.json b/packages/cmf-router/package.json index 881653050ac..0440b5a1079 100644 --- a/packages/cmf-router/package.json +++ b/packages/cmf-router/package.json @@ -21,7 +21,7 @@ "start": "echo nothing to start", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint" }, "dependencies": { diff --git a/packages/cmf/package.json b/packages/cmf/package.json index ee0f9aebcd1..382993afb6d 100644 --- a/packages/cmf/package.json +++ b/packages/cmf/package.json @@ -24,7 +24,7 @@ "start": "echo nothing to start", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "test:demo": "yarn jsdoc -c ./docs.json", "lint": "talend-scripts lint" }, diff --git a/packages/components/package.json b/packages/components/package.json index b9fd8ac26fa..8dd7398ffbc 100644 --- a/packages/components/package.json +++ b/packages/components/package.json @@ -24,7 +24,7 @@ "tsc": "tsc --emitDeclarationOnly --project ./tsconfig.json --outDir ./types", "test": "cross-env TZ=UTC talend-scripts test", "test:watch": "cross-env TZ=UTC talend-scripts test --watch", - "test:cov": "cross-env TZ=UTC talend-scripts test --coverage", + "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint", "start": "talend-scripts start -p 6006", "extract-i18n": "i18next-scanner --config i18next-scanner.config.js" diff --git a/packages/containers/package.json b/packages/containers/package.json index 82b16787f3a..e2eef008f09 100644 --- a/packages/containers/package.json +++ b/packages/containers/package.json @@ -24,7 +24,7 @@ "start": "talend-scripts start-storybook -p 6007", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "test:demo": "talend-scripts build-storybook --quiet", "lint": "talend-scripts lint", "extract-i18n": "i18next-scanner --config i18next-scanner.config.js" diff --git a/packages/dataviz/package.json b/packages/dataviz/package.json index 61b9f486c9f..61bb3154e0f 100644 --- a/packages/dataviz/package.json +++ b/packages/dataviz/package.json @@ -25,7 +25,7 @@ "test": "cross-env TZ=UTC talend-scripts test", "test:cy": "cypress run --component --spec **.cy.tsx", "test:watch": "cross-env TZ=UTC talend-scripts test --watch", - "test:cov": "cross-env TZ=UTC talend-scripts test --coverage" + "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --coverageReporters json-summary" }, "keywords": [ "react", diff --git a/packages/faceted-search-query-client/package.json b/packages/faceted-search-query-client/package.json index 7ad355888bb..db78062f15c 100644 --- a/packages/faceted-search-query-client/package.json +++ b/packages/faceted-search-query-client/package.json @@ -23,7 +23,7 @@ "build:lib:esm": "talend-scripts build --esm", "test": "cross-env TZ=UTC talend-scripts test", "test:watch": "cross-env TZ=UTC talend-scripts test --watch", - "test:cov": "cross-env TZ=UTC talend-scripts test --coverage", + "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint ./src/**/*.js ./stories/**/*.js ./.storybook/**/*.js", "extract-i18n": "i18next-scanner --config i18next-scanner.config.js" }, diff --git a/packages/faceted-search/package.json b/packages/faceted-search/package.json index f1208ce317f..03460045b58 100644 --- a/packages/faceted-search/package.json +++ b/packages/faceted-search/package.json @@ -23,7 +23,7 @@ "build:lib:esm": "talend-scripts build --esm", "test": "cross-env TZ=UTC talend-scripts test", "test:watch": "cross-env TZ=UTC talend-scripts test --watch", - "test:cov": "cross-env TZ=UTC talend-scripts test --coverage", + "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --coverageReporters json-summary", "test:demo": "talend-scripts build-storybook --quiet --docs", "lint": "talend-scripts lint ./src/**/*.js ./stories/**/*.js ./.storybook/**/*.js", "start": "talend-scripts start-storybook -p 6006", diff --git a/packages/forms/package.json b/packages/forms/package.json index 4fde531e4e9..9375423f341 100644 --- a/packages/forms/package.json +++ b/packages/forms/package.json @@ -24,7 +24,7 @@ "build:lib": "talend-scripts build", "test": "cross-env TZ=UTC talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint", "start": "talend-scripts start-storybook -p 6008", "extract-i18n": "i18next-scanner --config i18next-scanner.config.js" diff --git a/packages/icons/package.json b/packages/icons/package.json index 46f5b25786c..45b64df3b45 100644 --- a/packages/icons/package.json +++ b/packages/icons/package.json @@ -30,7 +30,6 @@ "build:lib:esm": "talend-scripts build --esm", "ts:types": "node scripts/typescript.js", "test": "echo no test", - "test:cov": "echo no test", "start-storybook": "talend-scripts start-storybook", "build-storybook": "talend-scripts build-storybook", "start": "talend-scripts start-storybook -p 6010", diff --git a/packages/sagas/package.json b/packages/sagas/package.json index ffc500b7a38..3bbf44a97cd 100644 --- a/packages/sagas/package.json +++ b/packages/sagas/package.json @@ -12,7 +12,7 @@ "build:lib": "talend-scripts build", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", - "test:cov": "talend-scripts test --coverage", + "test:cov": "talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint" }, "keywords": [ diff --git a/packages/stepper/package.json b/packages/stepper/package.json index 07ff24b359d..158730bb517 100644 --- a/packages/stepper/package.json +++ b/packages/stepper/package.json @@ -14,7 +14,7 @@ "test": "cross-env TZ=UTC talend-scripts test", "test:noisy": "cross-env TZ=UTC talend-scripts test", "test:watch": "cross-env TZ=UTC talend-scripts test --watch", - "test:cov": "cross-env TZ=UTC talend-scripts test --coverage", + "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --coverageReporters json-summary", "lint": "talend-scripts lint", "start": "talend-scripts start-storybook -p 6006" }, diff --git a/packages/theme/package.json b/packages/theme/package.json index 2d8f0a078f4..b452a9b1a43 100644 --- a/packages/theme/package.json +++ b/packages/theme/package.json @@ -8,7 +8,6 @@ "build:lib": "rimraf ./dist && webpack", "start": "webpack serve --mode=development", "test": "echo no test for @talend/bootstrap-theme", - "test:cov": "echo no test for @talend/bootstrap-theme", "lint": "talend-scripts lint" }, "keywords": [ diff --git a/packages/utils/package.json b/packages/utils/package.json index 8082483fe15..1e8b92f16a9 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -26,7 +26,7 @@ "build:lib:esm": "talend-scripts build --esm", "lint": "talend-scripts lint", "test": "cross-env TZ=UTC talend-scripts test", - "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --silent", + "test:cov": "cross-env TZ=UTC talend-scripts test --coverage --coverageReporters json-summary", "test:noisy": "cross-env TZ=UTC talend-scripts test", "test:watch": "cross-env TZ=UTC talend-scripts test --watch", "extends": "talend-scripts extends" diff --git a/turbo.json b/turbo.json index b49088b56db..39c7e8efece 100644 --- a/turbo.json +++ b/turbo.json @@ -20,8 +20,8 @@ }, "lint": {}, "check-types": {}, - "test": { - "dependsOn": ["^test"], + "test:cov": { + "dependsOn": ["^test:cov"], "outputs": ["coverage/**", "**/*.snap"] }, "test:update": {}, From 514c34bab2995f1ffcb8e5c8f8f22117b77fe372 Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 15:32:13 +0200 Subject: [PATCH 3/7] fix: remove adaptation and reconfigure turbo to support both lib and dist --- packages/theme/package.json | 2 +- turbo.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/theme/package.json b/packages/theme/package.json index b452a9b1a43..87f6c788ed8 100644 --- a/packages/theme/package.json +++ b/packages/theme/package.json @@ -6,8 +6,8 @@ "license": "Apache-2.0", "scripts": { "build:lib": "rimraf ./dist && webpack", + "pre-release": "webpack", "start": "webpack serve --mode=development", - "test": "echo no test for @talend/bootstrap-theme", "lint": "talend-scripts lint" }, "keywords": [ diff --git a/turbo.json b/turbo.json index 39c7e8efece..259b8c534f4 100644 --- a/turbo.json +++ b/turbo.json @@ -3,7 +3,7 @@ "tasks": { "build:lib": { "dependsOn": ["^build:lib"], - "outputs": ["lib/**"] + "outputs": ["lib/**", "dist/**"] }, "build:lib:esm": { "dependsOn": ["^build:lib:esm"], @@ -11,7 +11,7 @@ }, "pre-release": { "dependsOn": ["^pre-release"], - "outputs": ["dist"] + "outputs": ["dist/**"] }, "start": {}, "storybook:build": { From 1a1e95265bd30530fc1b4090dc80f02ab60dc7e0 Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 15:44:09 +0200 Subject: [PATCH 4/7] fix: build --- package.json | 2 +- packages/design-docs/.storybook/main.js | 6 +++--- turbo.json | 5 ++++- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 99f80307df7..3afb230df71 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,7 @@ "test": "cross-env TZ=UTC turbo run test", "test:update": "cross-env TZ=UTC talend-yarn-workspace run test --silent -u", "test:cov": "cross-env TZ=UTC turbo run test:cov", - "test:demo": "talend-yarn-workspace run test:demo", + "test:demo": "turbo run test:demo", "test:cron": "talend-yarn-workspace run test:cron", "start-components": "yarn workspace @talend/react-components run start", "start-containers": "yarn workspace @talend/react-containers run start", diff --git a/packages/design-docs/.storybook/main.js b/packages/design-docs/.storybook/main.js index 864e7de88d3..c3853368a79 100644 --- a/packages/design-docs/.storybook/main.js +++ b/packages/design-docs/.storybook/main.js @@ -1,7 +1,7 @@ import path from 'path'; import { packageDirectorySync } from 'pkg-dir'; -const iconConfig = require('@talend/icons/.storybook/main.js'); +// const iconConfig = require('@talend/icons/.storybook/main.js'); const rootPath = packageDirectorySync(); const { getJSAndTSLoader, @@ -30,8 +30,8 @@ const STORIES = [ export default { stories: STORIES, - webpackFinal: async originalConfig => { - const config = await iconConfig.webpackFinal(originalConfig); + webpackFinal: async config => { + // const config = await iconConfig.webpackFinal(originalConfig); // weird, replace the loader of the current storybook which do not support mono repo const rules = [ ...config.module.rules.filter(rule => { diff --git a/turbo.json b/turbo.json index 259b8c534f4..f50c37b8877 100644 --- a/turbo.json +++ b/turbo.json @@ -24,7 +24,10 @@ "dependsOn": ["^test:cov"], "outputs": ["coverage/**", "**/*.snap"] }, - "test:update": {}, + "test:demo": { + "dependsOn": ["^test:demo"], + "outputs": ["storybook-static/**", "jsdoc/**"] + }, "format:write": {}, "format:check": {} } From 6b64e65f523b1f8d565bb8f54cc0e2da996915a9 Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 15:46:35 +0200 Subject: [PATCH 5/7] chore: update CI config --- .github/workflows/pr-demo.yml | 10 +++++++++- .github/workflows/pr-test.yml | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pr-demo.yml b/.github/workflows/pr-demo.yml index eb40dca9fc9..787425c0d47 100644 --- a/.github/workflows/pr-demo.yml +++ b/.github/workflows/pr-demo.yml @@ -25,12 +25,20 @@ jobs: - name: Use Node.js uses: ./.github/actions/setup-node + - name: Cache Turbo + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 + with: + path: .turbo + key: turbo-${{ runner.os }}-${{ hashFiles('yarn.lock') }}-${{ hashFiles('turbo.json') }} + restore-keys: | + turbo-${{ runner.os }}-${{ hashFiles('yarn.lock') }}-${{ hashFiles('turbo.json') }} + - name: Install working-directory: ./ env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} run: yarn install --frozen-lockfile - + - name: Build Demo run: yarn test:demo diff --git a/.github/workflows/pr-test.yml b/.github/workflows/pr-test.yml index 0427ea3a23a..2cceb46ccff 100644 --- a/.github/workflows/pr-test.yml +++ b/.github/workflows/pr-test.yml @@ -30,9 +30,9 @@ jobs: uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 with: path: .turbo - key: turbo-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}-${{ hashFiles('turbo.json') }} + key: turbo-${{ runner.os }}-${{ hashFiles('yarn.lock') }}-${{ hashFiles('turbo.json') }} restore-keys: | - turbo-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}-${{ hashFiles('turbo.json') }} + turbo-${{ runner.os }}-${{ hashFiles('yarn.lock') }}-${{ hashFiles('turbo.json') }} - name: Install From ac5742ef94648193ba335dca14fe325d77739f5e Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 15:51:49 +0200 Subject: [PATCH 6/7] chore: cleanup --- turbo.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/turbo.json b/turbo.json index f50c37b8877..c7b705ea421 100644 --- a/turbo.json +++ b/turbo.json @@ -13,12 +13,14 @@ "dependsOn": ["^pre-release"], "outputs": ["dist/**"] }, - "start": {}, "storybook:build": { "dependsOn": ["^storybook:build"], "outputs": ["storybook-static/**"] }, - "lint": {}, + "lint": { + "dependsOn": ["^lint"], + "outputs": [] + }, "check-types": {}, "test:cov": { "dependsOn": ["^test:cov"], @@ -27,8 +29,6 @@ "test:demo": { "dependsOn": ["^test:demo"], "outputs": ["storybook-static/**", "jsdoc/**"] - }, - "format:write": {}, - "format:check": {} + } } } From ce10e1bf04b6c1ececb7d19dc8284972d72273c3 Mon Sep 17 00:00:00 2001 From: Jean-Michel FRANCOIS Date: Tue, 29 Jul 2025 16:22:58 +0200 Subject: [PATCH 7/7] chore: add clean commands --- fork/json-schema-form-core/package.json | 1 + fork/react-bootstrap/package.json | 3 ++- package.json | 4 ++++ packages/a11y/package.json | 1 + packages/assets-api/package.json | 1 + packages/cmf-cqrs/package.json | 1 + packages/cmf-router/package.json | 1 + packages/cmf/package.json | 1 + packages/components/package.json | 1 + packages/containers/package.json | 1 + packages/dataviz/package.json | 1 + packages/design-system/package.json | 1 + packages/design-tokens/package.json | 1 + packages/faceted-search-query-client/package.json | 1 + packages/faceted-search/package.json | 1 + packages/flow-designer/package.json | 1 + packages/forms/package.json | 1 + packages/http/package.json | 1 + packages/icons/package.json | 1 + packages/playground-vite/package.json | 1 + packages/playground/package.json | 1 + packages/router-bridge/package.json | 1 + packages/sagas/package.json | 1 + packages/stepper/package.json | 1 + packages/storybook-cmf/package.json | 1 + packages/storybook-docs/package.json | 1 + packages/theme/package.json | 1 + packages/utils/package.json | 1 + 28 files changed, 32 insertions(+), 1 deletion(-) diff --git a/fork/json-schema-form-core/package.json b/fork/json-schema-form-core/package.json index 2050c32a5aa..f8ae88f568e 100644 --- a/fork/json-schema-form-core/package.json +++ b/fork/json-schema-form-core/package.json @@ -13,6 +13,7 @@ "scripts": { "build:lib": "rimraf dist && talend-scripts build --umd", "build:lib:esm": "talend-scripts build --esm", + "clean": "rimraf dist lib-esm", "watch": "webpack --watch", "dist-untested": "webpack --config webpack.config.dist.js", "test:cov": "npm run test", diff --git a/fork/react-bootstrap/package.json b/fork/react-bootstrap/package.json index 79f103098e4..d6f651bcc7c 100644 --- a/fork/react-bootstrap/package.json +++ b/fork/react-bootstrap/package.json @@ -17,11 +17,12 @@ } }, "scripts": { + "build:lib": "talend-scripts build", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "build:lib:esm": "talend-scripts build --esm", + "clean": "rimraf lib dist", "pre-release": "yarn build:dev && yarn build:prod", - "build:lib": "talend-scripts build", "lint": "talend-scripts lint", "test": "talend-scripts test", "storybook": "start-storybook -p 6006", diff --git a/package.json b/package.json index b1de58581d7..62ff4435989 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,10 @@ }, "packageManager": "yarn@1.22.22", "scripts": { + "clean": "yarn clean:build && yarn clean:docs && yarn clean:cache", + "clean:build": "talend-yarn-workspace run clean", + "clean:docs": "rimraf */*/jsdoc */*/storybook-static", + "clean:cache": "rimraf */*/.turbo .turbo */*/node_modules/.cache node_modules/.cache */*/coverage", "postinstall": "yarn build:lib && yarn build:lib:esm", "build:lib": "turbo run build:lib", "build:lib:esm": "turbo run build:lib:esm", diff --git a/packages/a11y/package.json b/packages/a11y/package.json index 24c39ed57f4..4cd9446dcb1 100644 --- a/packages/a11y/package.json +++ b/packages/a11y/package.json @@ -13,6 +13,7 @@ } }, "scripts": { + "clean": "rimraf lib lib-esm", "build:lib": "talend-scripts build", "build:lib:esm": "talend-scripts build --esm", "test": "talend-scripts test", diff --git a/packages/assets-api/package.json b/packages/assets-api/package.json index ed01286a7da..214a408ca8f 100644 --- a/packages/assets-api/package.json +++ b/packages/assets-api/package.json @@ -15,6 +15,7 @@ "pre-release": "talend-scripts build --umd && talend-scripts build --umd --dev", "build:lib": "talend-scripts build", "build:lib:esm": "talend-scripts build --esm", + "clean": "rimraf lib lib-esm dist", "start": "echo nothing to start", "test": "talend-scripts test", "test:watch": "talend-scripts test --watch", diff --git a/packages/cmf-cqrs/package.json b/packages/cmf-cqrs/package.json index e4699b5a2f2..0eabcf28784 100644 --- a/packages/cmf-cqrs/package.json +++ b/packages/cmf-cqrs/package.json @@ -5,6 +5,7 @@ "mainSrc": "src/index.ts", "types": "lib/index.d.ts", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/cmf-router/package.json b/packages/cmf-router/package.json index 0440b5a1079..e2800dbeb62 100644 --- a/packages/cmf-router/package.json +++ b/packages/cmf-router/package.json @@ -13,6 +13,7 @@ "author": "Talend Frontend (http://www.talend.com)", "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "build:lib:esm": "talend-scripts build --esm", diff --git a/packages/cmf/package.json b/packages/cmf/package.json index 382993afb6d..726c6c8f1b1 100644 --- a/packages/cmf/package.json +++ b/packages/cmf/package.json @@ -16,6 +16,7 @@ } }, "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "build:lib:esm": "talend-scripts build --esm", diff --git a/packages/components/package.json b/packages/components/package.json index 8dd7398ffbc..3bf69482a6b 100644 --- a/packages/components/package.json +++ b/packages/components/package.json @@ -15,6 +15,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/containers/package.json b/packages/containers/package.json index e2eef008f09..9e1c298428a 100644 --- a/packages/containers/package.json +++ b/packages/containers/package.json @@ -16,6 +16,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/dataviz/package.json b/packages/dataviz/package.json index c95c6dabebe..677adc78df7 100644 --- a/packages/dataviz/package.json +++ b/packages/dataviz/package.json @@ -13,6 +13,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "pre-release": "yarn build:umd:dev && yarn build:umd:prod", "build:umd:dev": "talend-scripts build --umd --dev", "build:umd:prod": "talend-scripts build --umd", diff --git a/packages/design-system/package.json b/packages/design-system/package.json index 44bf0944e3e..45214ae5bf6 100644 --- a/packages/design-system/package.json +++ b/packages/design-system/package.json @@ -16,6 +16,7 @@ } }, "scripts": { + "clean": "rimraf lib lib-esm dist", "build:lib": "talend-scripts build", "build:lib:umd": "talend-scripts build --umd --dev", "build:lib:umd:min": "talend-scripts build --umd --prod", diff --git a/packages/design-tokens/package.json b/packages/design-tokens/package.json index 229d163c9f1..ab640fe72e9 100644 --- a/packages/design-tokens/package.json +++ b/packages/design-tokens/package.json @@ -28,6 +28,7 @@ } }, "scripts": { + "clean": "rimraf lib lib-esm dist", "pre-release": "echo nothing", "build:umd:dev": "talend-scripts build --umd --dev", "build:umd:prod": "talend-scripts build --umd", diff --git a/packages/faceted-search-query-client/package.json b/packages/faceted-search-query-client/package.json index db78062f15c..78270a3c9b2 100644 --- a/packages/faceted-search-query-client/package.json +++ b/packages/faceted-search-query-client/package.json @@ -16,6 +16,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/faceted-search/package.json b/packages/faceted-search/package.json index 03460045b58..62a078688ad 100644 --- a/packages/faceted-search/package.json +++ b/packages/faceted-search/package.json @@ -16,6 +16,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/flow-designer/package.json b/packages/flow-designer/package.json index 4aa49ddad75..5f9f79cfdad 100644 --- a/packages/flow-designer/package.json +++ b/packages/flow-designer/package.json @@ -6,6 +6,7 @@ "main": "lib/index.js", "mainSrc": "src/index.js", "scripts": { + "clean": "rimraf lib dist", "build:lib": "talend-scripts build", "lint": "talend-scripts lint", "test": "talend-scripts test", diff --git a/packages/forms/package.json b/packages/forms/package.json index 9375423f341..152af242ed4 100644 --- a/packages/forms/package.json +++ b/packages/forms/package.json @@ -16,6 +16,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "build:lib:esm": "talend-scripts build --esm", diff --git a/packages/http/package.json b/packages/http/package.json index 8fba51f749c..a692c5dc86a 100644 --- a/packages/http/package.json +++ b/packages/http/package.json @@ -18,6 +18,7 @@ "main": "lib/index.js", "mainSrc": "src/index.ts", "scripts": { + "clean": "rimraf lib dist", "build:lib": "talend-scripts build", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", diff --git a/packages/icons/package.json b/packages/icons/package.json index 45b64df3b45..93e52656a27 100644 --- a/packages/icons/package.json +++ b/packages/icons/package.json @@ -22,6 +22,7 @@ }, "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm dist", "build-umd": "webpack --config webpack.umd.js && webpack --config webpack.umd.js --env production", "build-ts": "tsc", "build-react": "node scripts/react.js", diff --git a/packages/playground-vite/package.json b/packages/playground-vite/package.json index 2b3472cc3ae..f199ae09676 100644 --- a/packages/playground-vite/package.json +++ b/packages/playground-vite/package.json @@ -6,6 +6,7 @@ "type": "module", "main": "app/index.js", "scripts": { + "clean": "rimraf dist", "build": "cross-env BASENAME='/playground' talend-scripts build", "test": "echo nothing to test in playground", "test:demo:umd": "cross-env BASENAME='/playground/' INITIATOR_URL='/playground/inject.js' talend-scripts build --prod", diff --git a/packages/playground/package.json b/packages/playground/package.json index c7bbc5b25e8..7e5621a759f 100644 --- a/packages/playground/package.json +++ b/packages/playground/package.json @@ -5,6 +5,7 @@ "private": true, "main": "app/index.js", "scripts": { + "clean": "rimraf dist", "build": "cross-env BASENAME='/playground' talend-scripts build", "test": "echo nothing to test in playground", "test:demo:umd": "cross-env BASENAME='/playground/' INITIATOR_URL='/playground/inject.js' talend-scripts build --prod", diff --git a/packages/router-bridge/package.json b/packages/router-bridge/package.json index 333f1bfb886..31b97bf111d 100644 --- a/packages/router-bridge/package.json +++ b/packages/router-bridge/package.json @@ -4,6 +4,7 @@ "description": "Bridge on top of cmf-router or react-router v5 + connected-react-router", "main": "lib/index.js", "scripts": { + "clean": "rimraf lib dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/sagas/package.json b/packages/sagas/package.json index 3bbf44a97cd..3ece6084318 100644 --- a/packages/sagas/package.json +++ b/packages/sagas/package.json @@ -6,6 +6,7 @@ "mainSrc": "src/index.js", "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/stepper/package.json b/packages/stepper/package.json index 158730bb517..11e0ede039e 100644 --- a/packages/stepper/package.json +++ b/packages/stepper/package.json @@ -6,6 +6,7 @@ "types": "lib/index.d.ts", "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib dist", "build:dev": "talend-scripts build --umd --dev", "build:prod": "talend-scripts build --umd --prod", "pre-release": "yarn build:dev && yarn build:prod", diff --git a/packages/storybook-cmf/package.json b/packages/storybook-cmf/package.json index fafe5b6cc6e..a8608a78fc0 100644 --- a/packages/storybook-cmf/package.json +++ b/packages/storybook-cmf/package.json @@ -17,6 +17,7 @@ "addon" ], "scripts": { + "clean": "rimraf lib", "build:lib": "talend-scripts build", "test": "talend-scripts test", "lint": "talend-scripts lint" diff --git a/packages/storybook-docs/package.json b/packages/storybook-docs/package.json index 17e322ebd7c..9d1146fbe30 100644 --- a/packages/storybook-docs/package.json +++ b/packages/storybook-docs/package.json @@ -5,6 +5,7 @@ "main": "lib/index.js", "types": "lib/index.d.ts", "scripts": { + "clean": "rimraf lib dist", "build:styles": "webpack --config webpack.custom.js --mode=production", "build:lib": "talend-scripts build && npm run build:styles", "start": "npm run storybook", diff --git a/packages/theme/package.json b/packages/theme/package.json index 87f6c788ed8..0a5c98bab60 100644 --- a/packages/theme/package.json +++ b/packages/theme/package.json @@ -5,6 +5,7 @@ "mainSrc": "src/index.js", "license": "Apache-2.0", "scripts": { + "clean": "rimraf dist", "build:lib": "rimraf ./dist && webpack", "pre-release": "webpack", "start": "webpack serve --mode=development", diff --git a/packages/utils/package.json b/packages/utils/package.json index 1e8b92f16a9..802faed70c9 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -22,6 +22,7 @@ "author": "Talend Frontend (http://www.talend.com)", "license": "Apache-2.0", "scripts": { + "clean": "rimraf lib lib-esm", "build:lib": "talend-scripts build --tsc", "build:lib:esm": "talend-scripts build --esm", "lint": "talend-scripts lint",