From bcb440ab21ed4119c07b345971b6b8659aeb428b Mon Sep 17 00:00:00 2001 From: Sofia Leon Date: Wed, 25 Jan 2023 00:22:35 -0800 Subject: [PATCH] build: add release-please config, fix owlbot-config --- .release-please-manifest.json | 1 + .../google-cloud-speech/{.github => }/.OwlBot.yaml | 6 ++---- packages/google-cloud-speech/.repo-metadata.json | 2 +- packages/google-cloud-speech/owlbot.py | 4 ++-- packages/google-cloud-speech/package.json | 13 +++++++++---- release-please-config.json | 3 ++- 6 files changed, 17 insertions(+), 12 deletions(-) rename packages/google-cloud-speech/{.github => }/.OwlBot.yaml (81%) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 1c680eaa626..317943f43d0 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -95,6 +95,7 @@ "packages/google-cloud-securitycenter": "7.1.0", "packages/google-cloud-servicedirectory": "4.0.5", "packages/google-cloud-shell": "2.0.4", + "packages/google-cloud-speech": "5.2.0", "packages/google-cloud-talent": "5.0.1", "packages/google-cloud-tasks": "3.0.5", "packages/google-cloud-texttospeech": "4.1.0", diff --git a/packages/google-cloud-speech/.github/.OwlBot.yaml b/packages/google-cloud-speech/.OwlBot.yaml similarity index 81% rename from packages/google-cloud-speech/.github/.OwlBot.yaml rename to packages/google-cloud-speech/.OwlBot.yaml index 365d4ef8b38..56d7a4e1e3f 100644 --- a/packages/google-cloud-speech/.github/.OwlBot.yaml +++ b/packages/google-cloud-speech/.OwlBot.yaml @@ -11,15 +11,13 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -docker: - image: gcr.io/cloud-devrel-public-resources/owlbot-nodejs:latest deep-remove-regex: - /owl-bot-staging deep-copy-regex: - - source: /google/cloud/speech/(v.*)/.*-nodejs/(.*) - dest: /owl-bot-staging/$1/$2 + - source: /google/cloud/speech/(v.*)/.*-nodejs + dest: /owl-bot-staging/google-cloud-speech/$1 begin-after-commit-hash: f43939eac6a0bb5998c1fa0f79063194e699230e diff --git a/packages/google-cloud-speech/.repo-metadata.json b/packages/google-cloud-speech/.repo-metadata.json index b70652540fc..0f074bc04db 100644 --- a/packages/google-cloud-speech/.repo-metadata.json +++ b/packages/google-cloud-speech/.repo-metadata.json @@ -6,7 +6,7 @@ "issue_tracker": "https://issuetracker.google.com/savedsearches/559758", "release_level": "stable", "language": "nodejs", - "repo": "googleapis/nodejs-speech", + "repo": "googleapis/google-cloud-node", "distribution_name": "@google-cloud/speech", "api_id": "speech.googleapis.com", "requires_billing": false, diff --git a/packages/google-cloud-speech/owlbot.py b/packages/google-cloud-speech/owlbot.py index bb21bbcb4a1..3b66219429f 100644 --- a/packages/google-cloud-speech/owlbot.py +++ b/packages/google-cloud-speech/owlbot.py @@ -16,7 +16,7 @@ import os import synthtool as s import synthtool.gcp as gcp -import synthtool.languages.node as node +import synthtool.languages.node_mono_repo as node import json import logging from pathlib import Path @@ -35,4 +35,4 @@ def patch(library: Path): '// eslint-disable-next-line @typescript-eslint/no-empty-interface\n' + 'export interface SpeechClient extends ImprovedStreamingClient {}\n' ) -node.owlbot_main(templates_excludes=["src/index.ts"], patch_staging=patch) +node.owlbot_main(relative_dir="packages/google-cloud-speech",templates_excludes=["src/index.ts"], patch_staging=patch) diff --git a/packages/google-cloud-speech/package.json b/packages/google-cloud-speech/package.json index d45872f8a9f..32a876ee84c 100644 --- a/packages/google-cloud-speech/package.json +++ b/packages/google-cloud-speech/package.json @@ -7,7 +7,11 @@ "engines": { "node": ">=12.0.0" }, - "repository": "googleapis/nodejs-speech", + "repository": { + "type": "git", + "directory": "packages/google-cloud-speech", + "url": "https://github.com/googleapis/google-cloud-node.git" + }, "main": "./build/src/index.js", "files": [ "build/protos", @@ -31,8 +35,8 @@ "scripts": { "docs": "jsdoc -c .jsdoc.js", "lint": "gts check", - "samples-test": "cd samples/ && npm link ../ && npm test && cd ../", - "system-test": "c8 mocha build/system-test/*.js --timeout 600000", + "samples-test": "npm run compile && cd samples/ && npm link ../ && npm i && npm test", + "system-test": "npm run compile && c8 mocha build/system-test", "test": "c8 mocha build/test/*.js", "fix": "gts fix", "docs-test": "linkinator docs", @@ -72,5 +76,6 @@ "typescript": "^4.6.4", "webpack": "^5.0.0", "webpack-cli": "^5.0.0" - } + }, + "homepage": "https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-speech" } diff --git a/release-please-config.json b/release-please-config.json index 1469ac66ded..d4447961eac 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -96,6 +96,7 @@ "packages/google-cloud-securitycenter": {}, "packages/google-cloud-servicedirectory": {}, "packages/google-cloud-shell": {}, + "packages/google-cloud-speech": {}, "packages/google-cloud-talent": {}, "packages/google-cloud-tasks": {}, "packages/google-cloud-texttospeech": {}, @@ -134,4 +135,4 @@ } ], "release-type": "node" -} \ No newline at end of file +}