From da89e53878d92467eb648c610e64f94a614915cc Mon Sep 17 00:00:00 2001 From: Tomo Suzuki Date: Mon, 18 Jul 2022 17:42:46 -0400 Subject: [PATCH] ci: update template so GAPIC_AUTO repos do not require special approvers for Java code (#1494) --- synthtool/gcp/templates/java_library/.github/CODEOWNERS | 3 +++ .../gcp/templates/java_library/.github/sync-repo-settings.yaml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/synthtool/gcp/templates/java_library/.github/CODEOWNERS b/synthtool/gcp/templates/java_library/.github/CODEOWNERS index f6961cac2..37403088c 100644 --- a/synthtool/gcp/templates/java_library/.github/CODEOWNERS +++ b/synthtool/gcp/templates/java_library/.github/CODEOWNERS @@ -6,7 +6,10 @@ {% if 'codeowner_team' in metadata['repo'] %} # The {{ metadata['repo']['codeowner_team'] }} is the default owner for changes in this repo * @googleapis/yoshi-java {{ metadata['repo']['codeowner_team'] }} +{% if 'library_type' in metadata['repo'] and metadata['repo']['library_type'] != 'GAPIC_AUTO' %} +# for handwritten libraries, keep codeowner_team in .repo-metadata.json as owner **/*.java {{ metadata['repo']['codeowner_team'] }} +{% endif %} {% else %} * @googleapis/yoshi-java {% endif %} diff --git a/synthtool/gcp/templates/java_library/.github/sync-repo-settings.yaml b/synthtool/gcp/templates/java_library/.github/sync-repo-settings.yaml index a5a31c42b..72acb9d8f 100644 --- a/synthtool/gcp/templates/java_library/.github/sync-repo-settings.yaml +++ b/synthtool/gcp/templates/java_library/.github/sync-repo-settings.yaml @@ -58,3 +58,6 @@ permissionRules: permission: admin - team: yoshi-java permission: push +- team: java-samples-reviewers + permission: push +