Skip to content

Commit 94a4f0c

Browse files
author
Ahmed Hamouda
committed
chore: migrate to yarn v4
1 parent 820a607 commit 94a4f0c

File tree

38 files changed

+40995
-29994
lines changed

38 files changed

+40995
-29994
lines changed

.github/actions/install-with-retries/install-with-retries.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ for i in {1..4}; do
2424

2525
if [ "$NO_LOCKFILE" = "true" ]; then
2626
echo "[LOG]: Ignoring yarn.lock file"
27-
yarn install --no-lockfile --network-timeout 60000
27+
YARN_HTTP_TIMEOUT=60000 yarn install --immutable
2828
else
29-
yarn install --network-timeout 60000
29+
YARN_HTTP_TIMEOUT=60000 yarn install
3030
fi
3131

3232
# Check return value and exit early if successful

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
.DS_Store
22
.env
33
.env.local
4+
.yarn
45
*.log
56
node_modules
67
aws-exports.js

.yarnrc.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
enableGlobalCache: false
2+
3+
enableTelemetry: false
4+
5+
httpTimeout: 60000
6+
7+
nodeLinker: node-modules
8+
9+
supportedArchitectures:
10+
cpu:
11+
- current
12+
os:
13+
- current
14+
15+
packageExtensions:
16+
"@angular-devkit/build-angular@*":
17+
dependencies:
18+
minimatch: "3.0.5"
19+
webpack: "^5.76.0"
20+
21+
"@size-limit/webpack@*":
22+
dependencies:
23+
webpack: "^5.76.0"
24+
25+
"serve-handler@*":
26+
dependencies:
27+
minimatch: "3.0.5"
28+
path-to-regexp: "3.3.0"
29+
30+
"codelyzer@*":
31+
dependencies:
32+
"@angular/core": "10.2.5"
33+
34+
"next-plugin-preval@*":
35+
dependencies:
36+
webpack: "^5.76.0"

docs/jest.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Config } from 'jest';
1+
import type { Config } from 'jest';
22

33
const jestConfig: Config = {
44
preset: 'ts-jest',

examples/angular/package.json

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,7 @@
4545
"tslint": "~6.1.0",
4646
"typescript": "~4.6.4"
4747
},
48-
"workspaces": {
49-
"nohoist": [
50-
"@types/jasmine"
51-
]
48+
"installConfig": {
49+
"hoistingLimits": "workspaces"
5250
}
5351
}

examples/next-app-router/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
"dependencies": {
1212
"@aws-amplify/ui-react": "6.12.0",
1313
"@aws-amplify/ui-react-storage": "3.12.1",
14-
"react": "^18.3.0",
1514
"next": "^14.2.31",
15+
"react": "^18.3.0",
1616
"react-dom": "^18",
1717
"react-icons": "^4.3.1"
1818
},

examples/react-native/package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,13 @@
4646
"react-native-dotenv": "^3.4.0",
4747
"react-native-launch-arguments": "^3.1.4"
4848
},
49+
"installConfig": {
50+
"hoistingLimits": "workspaces"
51+
},
4952
"jest": {
5053
"preset": "react-native"
5154
},
5255
"resolutions": {
5356
"react": "18"
5457
}
55-
}
58+
}

examples/vue/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
"private": true,
55
"type": "module",
66
"scripts": {
7-
"dev": "vite --port 3000",
8-
"build": "vue-tsc --noEmit && vite build",
7+
"dev": "yarn g:vite --port 3000",
8+
"build": "yarn g:vue-tsc --noEmit && yarn g:vite build",
99
"clean": "rimraf dist node_modules",
10-
"serve": "vite preview",
11-
"start": "vite preview --port 3000"
10+
"serve": "yarn g:vite preview",
11+
"start": "yarn g:vite preview --port 3000"
1212
},
1313
"dependencies": {
1414
"@aws-amplify/ui-vue": "^4.3.3",

package.json

Lines changed: 16 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
{
22
"private": true,
3-
"packageManager": "yarn@1.22.22",
3+
"packageManager": "yarn@4.9.4",
44
"name": "@aws-amplify/ui-monorepo",
55
"scripts": {
6-
"build": "turbo run build --filter=./packages/* --filter=!./packages/angular --filter=./packages/angular/projects/ui-angular",
7-
"build:exclude-angular": "turbo run build --filter=./packages/* --filter=!./packages/angular",
6+
"build": "turbo run build --filter='./packages/*' --filter='!./packages/angular' --filter='./packages/angular/projects/ui-angular'",
7+
"build:exclude-angular": "turbo run build --filter='./packages/*' --filter='!./packages/angular'",
88
"clean": "turbo run clean && rimraf node_modules",
9-
"lint": "turbo run lint --filter=./packages/* --filter=!./packages/angular --filter=./packages/angular/projects/ui-angular",
10-
"size": "turbo run size --filter=./packages/* --filter=!./packages/angular --filter=./packages/angular/projects/ui-angular",
11-
"test": "turbo run test --filter=./packages/* --filter=!./packages/angular --filter=./packages/angular/projects/ui-angular",
9+
"lint": "turbo run lint --filter='./packages/*' --filter='!./packages/angular' --filter='./packages/angular/projects/ui-angular'",
10+
"size": "turbo run size --filter='./packages/*' --filter='!./packages/angular' --filter='./packages/angular/projects/ui-angular'",
11+
"test": "turbo run test --filter='./packages/*' --filter='!./packages/angular' --filter='./packages/angular/projects/ui-angular' --concurrency=4",
1212
"setup": "yarn install && yarn build",
1313
"refresh": "yarn clean && yarn setup",
1414
"angular": "yarn workspace @aws-amplify/ui-angular",
@@ -46,7 +46,13 @@
4646
"version:hotfix": "yarn changeset && yarn bumpVersions && yarn angular build",
4747
"publish:hotfix": "yarn changeset publish --tag hotfix",
4848
"generateVersions": "node scripts/generateVersion",
49-
"bumpVersions": "yarn changeset version && yarn generateVersions"
49+
"bumpVersions": "yarn changeset version && yarn generateVersions",
50+
"g:jest": "cd $INIT_CWD && jest",
51+
"g:rimraf": "cd $INIT_CWD && rimraf",
52+
"g:rollup": "cd $INIT_CWD && rollup",
53+
"g:tsc": "cd $INIT_CWD && tsc",
54+
"g:vite": "cd $INIT_CWD && vite",
55+
"g:vue-tsc": "cd $INIT_CWD && vue-tsc"
5056
},
5157
"workspaces": {
5258
"packages": [
@@ -56,28 +62,10 @@
5662
"packages/*",
5763
"packages/angular/projects/ui-angular",
5864
"packages/configs/*"
59-
],
60-
"nohoist": [
61-
"**/@react-native-community/**",
62-
"**/react-native",
63-
"**/react-native-paper",
64-
"**/react-native-safe-area-context",
65-
"**/react-native-url-polyfill",
66-
"**/react-native-vector-icons",
67-
"**/rollup",
68-
"**/@types/webgl-ext",
69-
"**/@types/webgl-ext/**"
7065
]
7166
},
7267
"resolutions": {
73-
"**/@react-native-community/**/fast-xml-parser": "^4.4.1",
74-
"**/@aws-*/**/fast-xml-parser": "^4.4.1",
75-
"**/@aws-amplify/ui-angular-example/**/codelyzer/**/@angular/core": "10.2.5",
76-
"**/@angular-devkit/build-angular/minimatch": "3.0.5",
77-
"**/@angular-devkit/build-angular/webpack": "^5.76.0",
78-
"**/@size-limit/webpack/webpack": "^5.76.0",
79-
"**/serve/serve-handler/minimatch": "3.0.5",
80-
"**/serve/serve-handler/path-to-regexp": "3.3.0",
68+
"fast-xml-parser": "^4.4.1",
8169
"@aws-amplify/data-schema": "^1.19.0",
8270
"@adobe/css-tools": "^4.3.2",
8371
"@sideway/formula": "^3.0.1",
@@ -86,7 +74,6 @@
8674
"body-parser": "1.20.3",
8775
"cookie": "^0.7.0",
8876
"cross-spawn": "7.0.5",
89-
"docs/next-plugin-preval/webpack": "^5.76.0",
9077
"esbuild": "^0.25.0",
9178
"follow-redirects": "^1.15.6",
9279
"json5": "^2.2.1",
@@ -141,6 +128,8 @@
141128
"jest-environment-jsdom": "^29.7.0",
142129
"lint-staged": ">=10",
143130
"prettier": "^3.0.3",
131+
"react": "^18.3.0",
132+
"react-native": "0.71.16",
144133
"react-test-renderer": "^18.3.0",
145134
"rimraf": "^5.0.0",
146135
"rollup": "^4.22.4",

packages/angular/package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"dev": "ng build --watch",
88
"start": "ng serve",
99
"build": "ng build --configuration production",
10-
"test": "jest",
10+
"test": "yarn g:jest",
1111
"test:watch": "yarn test --watch",
1212
"lint": "yarn typecheck && ng lint",
1313
"typecheck": "tsc --noEmit"
@@ -22,6 +22,7 @@
2222
"@angular-eslint/template-parser": "~14.4.0",
2323
"@angular/animations": "^14.3.0",
2424
"@angular/cli": "^14.2.13",
25+
"@angular/common": "^14.3.0",
2526
"@angular/compiler": "^14.3.0",
2627
"@angular/compiler-cli": "^14.3.0",
2728
"@angular/core": "^14.3.0",
@@ -41,10 +42,8 @@
4142
"typescript": "~4.6.4",
4243
"zone.js": "^0.13.0"
4344
},
44-
"workspaces": {
45-
"nohoist": [
46-
"@angular-devkit/build-angular"
47-
]
45+
"installConfig": {
46+
"hoistingLimits": "workspaces"
4847
},
4948
"typings": "./dist/ui-angular/index.d.ts",
5049
"overrides": {

0 commit comments

Comments
 (0)