From 108e4624f9dd4fece5cf9d5c258684d5b8a51f55 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Fri, 31 Jul 2020 12:52:22 -0700 Subject: [PATCH] chore: regen common template (#628) * changes without context autosynth cannot find the source of changes triggered by earlier changes in this repository, or by version upgrades to tools such as linters. * Add cloud-RAD for Java Co-authored-by: Jeff Ching Source-Author: Les Vogel Source-Date: Thu Jul 30 13:09:50 2020 -0700 Source-Repo: googleapis/synthtool Source-Sha: dd230c816f88d0141fcd0be83498986287220d1b Source-Link: https://github.com/googleapis/synthtool/commit/dd230c816f88d0141fcd0be83498986287220d1b --- .kokoro/release/publish_javadoc.cfg | 10 ++++++++++ .kokoro/release/publish_javadoc.sh | 25 +++++++++++++++++++++++-- synth.metadata | 2 +- 3 files changed, 34 insertions(+), 3 deletions(-) diff --git a/.kokoro/release/publish_javadoc.cfg b/.kokoro/release/publish_javadoc.cfg index e2fbf8c11..cb5db9947 100644 --- a/.kokoro/release/publish_javadoc.cfg +++ b/.kokoro/release/publish_javadoc.cfg @@ -1,14 +1,24 @@ # Format: //devtools/kokoro/config/proto/build.proto + +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/doc-templates/" + env_vars: { key: "STAGING_BUCKET" value: "docs-staging" } +env_vars: { + key: "STAGING_BUCKET_V2" + value: "docs-staging-v2-staging" + # Production will be at: docs-staging-v2 +} + env_vars: { key: "TRAMPOLINE_BUILD_FILE" value: "github/java-bigquery/.kokoro/release/publish_javadoc.sh" } + before_action { fetch_keystore { keystore_resource { diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh index a5a508ba4..8aa3449bc 100755 --- a/.kokoro/release/publish_javadoc.sh +++ b/.kokoro/release/publish_javadoc.sh @@ -24,6 +24,11 @@ if [[ -z "${STAGING_BUCKET}" ]]; then exit 1 fi +if [[ -z "${STAGING_BUCKET_V2}" ]]; then + echo "Need to set STAGING_BUCKET_V2 environment variable" + exit 1 +fi + # work from the git root directory pushd $(dirname "$0")/../../ @@ -31,13 +36,13 @@ pushd $(dirname "$0")/../../ python3 -m pip install gcp-docuploader # compile all packages -mvn clean install -B -DskipTests=true +mvn clean install -B -q -DskipTests=true NAME=google-cloud-bigquery VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3) # build the docs -mvn site -B +mvn site -B -q pushd target/site/apidocs @@ -53,3 +58,19 @@ python3 -m docuploader upload . \ --staging-bucket ${STAGING_BUCKET} popd + +# V2 +mvn clean site -B -q -Ddevsite.template="${KOKORO_GFILE_DIR}/java/" + +pushd target/devsite + +# create metadata +python3 -m docuploader create-metadata \ + --name ${NAME} \ + --version ${VERSION} \ + --language java + +# upload docs +python3 -m docuploader upload . \ + --credentials ${CREDENTIALS} \ + --staging-bucket ${STAGING_BUCKET_V2} diff --git a/synth.metadata b/synth.metadata index 8a2941c51..81e04270d 100644 --- a/synth.metadata +++ b/synth.metadata @@ -11,7 +11,7 @@ "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "4f2c9f752a94042472fc03c5bd9e06e89817d2bd" + "sha": "dd230c816f88d0141fcd0be83498986287220d1b" } } ],