Skip to content

Commit 1e05730

Browse files
adamthom-amznsrchase
authored andcommitted
Convert from lerna to turborepo
lerna wasn't used for much, and had dependencies that popped up on yarn audit, so this switches to a basic turborepo setup that has no flagged dependencies.
1 parent 840363a commit 1e05730

File tree

7 files changed

+182
-4037
lines changed

7 files changed

+182
-4037
lines changed

smithy-typescript-ssdk-libs/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
**/*.d.ts
44
**/yarn-error.log
55
coverage
6+
**/.turbo

smithy-typescript-ssdk-libs/lerna.json

Lines changed: 0 additions & 10 deletions
This file was deleted.

smithy-typescript-ssdk-libs/package.json

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,11 @@
55
"description": "Smithy TypeScript SSDK packages",
66
"main": "index.js",
77
"scripts": {
8-
"clean": "yarn clear-build-cache && yarn clear-build-info && lerna clean -y",
9-
"clear-build-cache": "rimraf ./*/dist ./*/types, ./*/*.tgz",
10-
"clear-build-info": "rimraf **/*.tsbuildinfo",
11-
"build": "lerna run build",
12-
"pretest": "yarn build",
13-
"test": "jest",
14-
"lint": "yarn run eslint **/src/**/*.ts",
15-
"format": "prettier --write **/*.{ts,js,md,json}"
8+
"clean": "turbo run clean --force --parallel",
9+
"build": "turbo run build",
10+
"test": "turbo run test",
11+
"lint": "turbo run lint --parallel",
12+
"format": "turbo run format --parallel"
1613
},
1714
"repository": {
1815
"type": "git",
@@ -26,22 +23,23 @@
2623
},
2724
"devDependencies": {
2825
"@types/jest": "^26.0.4",
29-
"lerna": "3.22.1",
30-
"jest": "^26.1.0",
31-
"ts-jest": "^26.4.1",
32-
"yarn": "1.22.10",
33-
"prettier": "2.2.1",
34-
"typescript": "~4.2.4",
26+
"@typescript-eslint/eslint-plugin": "4.30.0",
27+
"@typescript-eslint/parser": "4.30.0",
3528
"eslint": "7.32.0",
3629
"eslint-config-prettier": "8.3.0",
3730
"eslint-plugin-prettier": "3.4.1",
3831
"eslint-plugin-simple-import-sort": "7.0.0",
39-
"@typescript-eslint/eslint-plugin": "4.30.0",
40-
"@typescript-eslint/parser": "4.30.0"
32+
"jest": "^26.1.0",
33+
"prettier": "2.2.1",
34+
"ts-jest": "^26.4.1",
35+
"turbo": "^1.1.2",
36+
"typescript": "~4.2.4",
37+
"yarn": "1.22.10"
4138
},
4239
"workspaces": {
4340
"packages": [
4441
"*"
4542
]
46-
}
43+
},
44+
"packageManager": "[email protected]"
4745
}

smithy-typescript-ssdk-libs/server-apigateway/package.json

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@
99
"pretest": "yarn build",
1010
"build": "tsc -p tsconfig.json",
1111
"postbuild": "rimraf dist/types/ts3.4 && downlevel-dts dist/types dist/types/ts3.4",
12-
"test": "jest"
12+
"test": "jest --passWithNoTests",
13+
"clean": "rimraf dist",
14+
"lint": "yarn run eslint -c ../.eslintrc.js **/src/**/*.ts",
15+
"format": "prettier --config ../prettier.config.js --write **/*.{ts,js,md,json}"
1316
},
1417
"repository": {
1518
"type": "git",
@@ -19,8 +22,8 @@
1922
"author": "AWS Smithy Team",
2023
"license": "Apache-2.0",
2124
"dependencies": {
22-
"@aws-sdk/protocol-http": "3.40.0",
23-
"@aws-sdk/types": "3.40.0",
25+
"@aws-sdk/protocol-http": "^3.40.0",
26+
"@aws-sdk/types": "^3.40.0",
2427
"@types/aws-lambda": "^8.10.72",
2528
"tslib": "^1.8.0"
2629
},

smithy-typescript-ssdk-libs/server-common/package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
"pretest": "yarn build",
1010
"build": "tsc -p tsconfig.json",
1111
"postbuild": "rimraf dist/types/ts3.4 && downlevel-dts dist/types dist/types/ts3.4",
12-
"test": "jest"
12+
"test": "jest",
13+
"clean": "rimraf dist",
14+
"format": "prettier --config ../prettier.config.js --write **/*.{ts,js,md,json}"
1315
},
1416
"repository": {
1517
"type": "git",
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"$schema": "https://turborepo.org/schema.json",
3+
"baseBranch": "origin/main",
4+
"pipeline": {
5+
"build": {
6+
"dependsOn": ["^build"]
7+
},
8+
"test": {
9+
"dependsOn": ["build"],
10+
"outputs": []
11+
},
12+
"lint": {
13+
"outputs": []
14+
},
15+
"format": {
16+
"outputs": []
17+
},
18+
"clean": {
19+
"cache": false
20+
}
21+
}
22+
}

0 commit comments

Comments
 (0)