Skip to content

Commit 2ebb1fb

Browse files
feat!: drop Node 12 & decouple development dependencies (#1439)
* feat!: get tools scripts and dependencies running; still need to get top-level module running without tools, remove extra dependencies, and make sure to run commands from the tools dependency * move to node 14 --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent e81b967 commit 2ebb1fb

34 files changed

Lines changed: 4160 additions & 40 deletions

packages/packages/google-gax/owlbot.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@
1414

1515
import synthtool.languages.node as node
1616

17-
node.owlbot_main(templates_excludes=["LICENSE", "README.md", ".github/sync-repo-settings.yaml"])
17+
node.owlbot_main(templates_excludes=["LICENSE", "README.md", ".github/sync-repo-settings.yaml", ".github/workflows/ci.yaml",".kokoro/", ".kokoro/continuous/node12/common.cfg", ".kokoro/presubmit/node12/common.cfg", ".kokoro/release/docs.cfg", ".kokoro/release/publish.cfg"])

packages/packages/google-gax/package.json

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,13 @@
66
"types": "build/src/index.d.ts",
77
"files": [
88
"build/src",
9-
"build/tools/compileProtos.js",
10-
"build/tools/minify.js",
11-
"build/protos/"
9+
"build/protos/",
10+
"!build/src/**/*.map"
1211
],
13-
"bin": {
14-
"compileProtos": "build/tools/compileProtos.js",
15-
"minifyProtoJson": "build/tools/minify.js"
16-
},
1712
"dependencies": {
1813
"@grpc/grpc-js": "~1.8.0",
1914
"@grpc/proto-loader": "^0.7.0",
2015
"@types/long": "^4.0.0",
21-
"@types/rimraf": "^3.0.2",
2216
"abort-controller": "^3.0.0",
2317
"duplexify": "^4.0.0",
2418
"fast-text-encoding": "^1.0.3",
@@ -28,7 +22,6 @@
2822
"object-hash": "^3.0.0",
2923
"proto3-json-serializer": "^1.0.0",
3024
"protobufjs": "7.2.3",
31-
"protobufjs-cli": "1.1.1",
3225
"retry-request": "^5.0.0"
3326
},
3427
"devDependencies": {
@@ -40,11 +33,13 @@
4033
"@types/object-hash": "^3.0.0",
4134
"@types/proxyquire": "^1.3.28",
4235
"@types/pumpify": "^1.4.1",
36+
"@types/rimraf": "^3.0.2",
4337
"@types/sinon": "^10.0.0",
4438
"@types/uglify-js": "^3.17.0",
4539
"c8": "^7.0.0",
4640
"codecov": "^3.1.0",
4741
"execa": "^5.0.0",
42+
"gapic-tools": "^0.1.7",
4843
"google-proto-files": "^3.0.0",
4944
"gts": "^3.1.0",
5045
"linkinator": "^4.0.0",
@@ -53,6 +48,7 @@
5348
"mocha": "^9.0.0",
5449
"ncp": "^2.0.0",
5550
"null-loader": "^4.0.0",
51+
"protobufjs-cli": "1.1.1",
5652
"proxyquire": "^2.0.1",
5753
"pumpify": "^2.0.0",
5854
"rimraf": "^3.0.2",
@@ -69,7 +65,7 @@
6965
"docs": "compodoc src/",
7066
"pretest": "npm run prepare",
7167
"test": "c8 mocha build/test/unit",
72-
"lint": "gts check",
68+
"lint": "gts check src samples test",
7369
"clean": "gts clean",
7470
"compile": "tsc -p . && cp src/*.json build/src && cp -r test/fixtures build/test && cp -r protos build/",
7571
"compile-operation-protos": "pbjs -t json google/longrunning/operations.proto -p ./protos > protos/operations.json && pbjs -t static-module -r operations_protos google/longrunning/operations.proto -p ./protos > protos/operations.js && pbts protos/operations.js -o protos/operations.d.ts",
@@ -80,7 +76,7 @@
8076
"compile-http-protos": "pbjs -t static-module -r http_proto --keep-case google/api/http.proto -p ./protos > protos/http.js && pbts protos/http.js -o protos/http.d.ts",
8177
"compile-showcase-proto": "pbjs -t json google/showcase/v1beta1/echo.proto google/showcase/v1beta1/identity.proto google/showcase/v1beta1/messaging.proto google/showcase/v1beta1/testing.proto -p ./protos > test/fixtures/google-gax-packaging-test-app/protos/protos.json && pbjs -t static-module -r showcase_protos google/showcase/v1beta1/echo.proto google/showcase/v1beta1/identity.proto google/showcase/v1beta1/messaging.proto google/showcase/v1beta1/testing.proto -p ./protos > test/fixtures/google-gax-packaging-test-app/protos/protos.js && pbts test/fixtures/google-gax-packaging-test-app/protos/protos.js -o test/fixtures/google-gax-packaging-test-app/protos/protos.d.ts",
8278
"fix": "gts fix",
83-
"prepare": "npm run compile && node ./build/tools/prepublish.js && mkdirp build/protos && cp -r protos/* build/protos/ && npm run minify-proto-json",
79+
"prepare": "npm run compile && prepublishProtos . && mkdirp build/protos && cp -r protos/* build/protos/ && npm run minify-proto-json",
8480
"system-test": "c8 mocha build/test/system-test --timeout 600000 && npm run test-application",
8581
"samples-test": "cd samples/ && npm link ../ && npm test && cd ../",
8682
"docs-test": "linkinator docs",
@@ -89,8 +85,8 @@
8985
"test-application": "cd test/test-application && npm run prefetch && npm install && npm start",
9086
"prelint": "cd samples; npm link ../; npm install",
9187
"precompile": "gts clean",
92-
"update-protos": "node ./build/tools/listProtos.js",
93-
"minify-proto-json": "node ./build/tools/minify.js"
88+
"update-protos": "listProtos .",
89+
"minify-proto-json": "minifyProtoJson"
9490
},
9591
"repository": "googleapis/gax-nodejs",
9692
"keywords": [
@@ -103,7 +99,7 @@
10399
},
104100
"homepage": "https://github.com/googleapis/gax-nodejs#readme",
105101
"engines": {
106-
"node": ">=12"
102+
"node": ">=14"
107103
},
108104
"browser": "build/src/fallback.js"
109105
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"initial-version": "0.1.0",
3+
"packages": {
4+
".": {},
5+
"tools": {}
6+
},
7+
"release-type": "node"
8+
}
9+
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
".": "3.6.0",
3+
"tools": "0.1.7"
4+
}

packages/packages/google-gax/test/showcase-echo-client/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,10 @@
3838
},
3939
"devDependencies": {
4040
"@types/node": "^16.0.0",
41+
"gapic-tools": "^0.1.7",
4142
"typescript": "^4.5.5"
4243
},
4344
"engines": {
44-
"node": ">=v12"
45+
"node": ">=v14"
4546
}
4647
}

packages/packages/google-gax/test/test-application/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@
3131
"protobufjs": "^7.0.0"
3232
},
3333
"engines": {
34-
"node": ">=12.0.0"
34+
"node": ">=14.0.0"
3535
}
3636
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
**/node_modules
2+
**/coverage
3+
test/fixtures
4+
build/
5+
docs/
6+
protos/
7+
samples/generated/
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"extends": "./node_modules/gts",
3+
"root": true
4+
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
coverage
2+
npm-debug.log
3+
**/*.log
4+
**/node_modules
5+
.coverage
6+
.nyc_output
7+
docs/
8+
protos/google/
9+
out/
10+
system-test/secrets.js
11+
system-test/*key.json
12+
build
13+
.vscode
14+
package-lock.json
15+
.system-test-run/
16+
.kitchen-sink/
17+
.showcase-server-dir/
18+
.compileProtos-test/
19+
.minify-test/
20+
__pycache__
21+
doc/
22+
dist/
23+
*.tgz
24+
**/*.tgz
25+
test/showcase-echo-client/protos/protos.*
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
**/node_modules
2+
**/coverage
3+
test/fixtures
4+
build/
5+
docs/
6+
protos/

0 commit comments

Comments
 (0)