From 7ec90041cb51d7d43bd3c36113e9f0929a464287 Mon Sep 17 00:00:00 2001 From: Brijesh Bittu Date: Fri, 1 Sep 2023 10:52:11 +0530 Subject: [PATCH] [core] re-add nx and setup build caching --- apps/zero-runtime-vite-app/README.md | 2 +- docs/.link-check-errors.txt | 1 - nx.json | 12 ++++++++++++ package.json | 4 ++-- 4 files changed, 15 insertions(+), 4 deletions(-) create mode 100644 nx.json diff --git a/apps/zero-runtime-vite-app/README.md b/apps/zero-runtime-vite-app/README.md index 225a4c1bd28553..5b2a039de9e679 100644 --- a/apps/zero-runtime-vite-app/README.md +++ b/apps/zero-runtime-vite-app/README.md @@ -13,7 +13,7 @@ You can either run `yarn release:build` command to build all the packages, or yo Make sure you have also run `yarn release:build` at least once because we also use `@mui/material` and `@mui/system` packages. On subsequent runs, you can only build the above 2 packages using - ```bash -yarn build:zero +yarn build ``` After building, you can run the project by changing into the directory and then diff --git a/docs/.link-check-errors.txt b/docs/.link-check-errors.txt index fa2fd09db8da38..4f82b8fd7ece91 100644 --- a/docs/.link-check-errors.txt +++ b/docs/.link-check-errors.txt @@ -1,5 +1,4 @@ Broken links found by `yarn docs:link-check` that exist: - https://mui.com/blog/material-ui-v4-is-out/#premium-themes-store-✨ -- https://mui.com/joy-ui/integrations/material-ui/ - https://mui.com/size-snapshot diff --git a/nx.json b/nx.json new file mode 100644 index 00000000000000..bcba7dd2f0b563 --- /dev/null +++ b/nx.json @@ -0,0 +1,12 @@ +{ + "$schema": "./node_modules/nx/schemas/nx-schema.json", + "extends": "nx/presets/npm.json", + "tasksRunnerOptions": { + "default": { + "runner": "nx/tasks-runners/default", + "options": { + "cacheableOperations": ["build"] + } + } + } +} diff --git a/package.json b/package.json index 241bf020320f85..a33bf93693b170 100644 --- a/package.json +++ b/package.json @@ -6,10 +6,10 @@ "proptypes": "cross-env BABEL_ENV=development babel-node --extensions \".tsx,.ts,.js\" ./scripts/generateProptypes.ts", "deduplicate": "node scripts/deduplicate.mjs", "benchmark:browser": "yarn workspace benchmark browser", + "build": "lerna run --parallel --scope \"@mui/*\" build", "build:codesandbox": "NODE_OPTIONS=\"–max_old_space_size=4096\" lerna run --concurrency 8 --scope \"@mui/*\" build", - "build:zero": "lerna run --parallel --scope \"@mui/zero*\" build", "release:version": "lerna version --no-changelog --no-push --no-git-tag-version --force-publish=@mui/core-downloads-tracker", - "release:build": "lerna run --parallel --scope \"@mui/*\" build", + "release:build": "lerna run --parallel --scope \"@mui/*\" build --skip-nx-cache", "release:changelog": "node scripts/releaseChangelog.mjs", "release:publish": "lerna publish from-package --dist-tag latest --contents build", "release:publish:dry-run": "lerna publish from-package --dist-tag latest --contents build --registry=\"http://localhost:4873/\"",