diff --git a/.kokoro/docs/publish.sh b/.kokoro/docs/publish.sh index 449c16b592ce..698051844a6f 100755 --- a/.kokoro/docs/publish.sh +++ b/.kokoro/docs/publish.sh @@ -21,6 +21,11 @@ fi if [ "$STAGING_BUCKET" != "" ]; then echo "Using staging bucket ${STAGING_BUCKET}..." fi +VERBOSITY=""; +if [ "$GCLOUD_DEBUG" -eq 1 ]; then + echo "Setting verbosity to VERBOSE..."; + VERBOSITY=" -v"; +fi find $PROJECT_DIR/* -mindepth 1 -maxdepth 1 -name 'composer.json' -not -path '*vendor/*' -regex "$PROJECT_DIR/[A-Z].*" -exec dirname {} \; | while read DIR do @@ -31,13 +36,15 @@ do --component $COMPONENT \ --out $DIR/out \ --metadata-version $VERSION \ - --staging-bucket $STAGING_BUCKET + --staging-bucket $STAGING_BUCKET \ + $VERBOSITY else # dry run $PROJECT_DIR/dev/google-cloud docfx \ --component $COMPONENT \ --out $DIR/out \ - --metadata-version $VERSION + --metadata-version $VERSION \ + $VERBOSITY fi done @@ -77,4 +84,4 @@ if [ "$KOKORO_GITHUB_COMMIT" != "" ]; then composer update -d "$module" cp "$module/composer.lock" "pkg/$module/composer.lock" done -fi \ No newline at end of file +fi diff --git a/Firestore/src/Admin/V1/FirestoreAdminClient.php b/Firestore/src/Admin/V1/FirestoreAdminClient.php index 132569cbeb2d..5c179ce86e84 100644 --- a/Firestore/src/Admin/V1/FirestoreAdminClient.php +++ b/Firestore/src/Admin/V1/FirestoreAdminClient.php @@ -18,7 +18,7 @@ /* * GENERATED CODE WARNING * Generated by gapic-generator-php from the file - * https://github.com/google/googleapis/blob/master/google/firestore/admin/v1/firestore_admin.proto + * https://github.com/googleapis/googleapis/blob/master/google/firestore/admin/v1/firestore_admin.proto * Updates to the above are reflected here through a refresh process. */ @@ -31,7 +31,7 @@ class FirestoreAdminClient extends FirestoreAdminGapicClient { /** - * @see FirestoreAdminClient::createIndexLRO + * @see FirestoreAdminClient::createIndexLRO() * @return \Google\LongRunning\Operation * @deprecated use createIndexLRO instead */ @@ -41,7 +41,7 @@ public function createIndex($parent, $index, array $optionalArgs = []) } /** - * @see FirestoreAdminClient::exportDocumentsLRO + * @see FirestoreAdminClient::exportDocumentsLRO() * @return \Google\LongRunning\Operation * @deprecated use exportDocumentsLRO instead */ @@ -51,7 +51,7 @@ public function exportDocuments($name, array $optionalArgs = []) } /** - * @see FirestoreAdminClient::importDocumentsLRO + * @see FirestoreAdminClient::importDocumentsLRO() * @return \Google\LongRunning\Operation * @deprecated use importDocumentsLRO instead */ @@ -63,7 +63,7 @@ public function importDocuments($name, array $optionalArgs = []) /** * @return \Google\LongRunning\Operation * @deprecated use updateFieldLRO instead - * @see FirestoreAdminClient::updateFieldLRO + * @see FirestoreAdminClient::updateFieldLRO() */ public function updateField($field, array $optionalArgs = []) { diff --git a/Firestore/src/V1/FirestoreClient.php b/Firestore/src/V1/FirestoreClient.php index a4cee8168dd1..cbd4889f5af2 100644 --- a/Firestore/src/V1/FirestoreClient.php +++ b/Firestore/src/V1/FirestoreClient.php @@ -18,7 +18,7 @@ /* * GENERATED CODE WARNING * This file was generated from the file - * https://github.com/google/googleapis/blob/master/google/firestore/v1/firestore.proto + * https://github.com/googleapis/googleapis/blob/master/google/firestore/v1/firestore.proto * and updates to that file get reflected here through a refresh process. * * @experimental diff --git a/PubSub/src/PubSubClient.php b/PubSub/src/PubSubClient.php index d40e736a53fc..bdaddd2d94c3 100644 --- a/PubSub/src/PubSubClient.php +++ b/PubSub/src/PubSubClient.php @@ -262,7 +262,7 @@ public function createTopic($name, array $options = []) * Lazily instantiate a topic with a topic name. * * No API requests are made by this method. If you want to create a new - * topic, use {@see Topic::createTopic()}. + * topic, use {@see Topic::create()}. * * Example: * ``` diff --git a/dev/src/DocFx/Node/ClassNode.php b/dev/src/DocFx/Node/ClassNode.php index 9ec6b0ad16eb..f4b90c25647a 100644 --- a/dev/src/DocFx/Node/ClassNode.php +++ b/dev/src/DocFx/Node/ClassNode.php @@ -98,10 +98,11 @@ public function isServiceBaseClass(): bool public function isV2ServiceClass(): bool { // returns true if the class does not extend another class and isn't a - // base class + // base class and it contains a "Client" namespace if (!$this->getExtends() && !$this->isServiceBaseClass() && 'Client' === substr($this->getName(), -6) + && false !== strpos($this->getFullName(), '\\Client\\') ) { return true; } diff --git a/dev/src/DocFx/XrefValidationTrait.php b/dev/src/DocFx/XrefValidationTrait.php index caf5790fb438..d1f0a5c3f4c9 100644 --- a/dev/src/DocFx/XrefValidationTrait.php +++ b/dev/src/DocFx/XrefValidationTrait.php @@ -64,7 +64,7 @@ private function getBrokenXrefs(string $description): array { $brokenRefs = []; preg_replace_callback( - '/([^ ]*)<\/xref>/', function ($matches) use (&$brokenRefs) { // Valid external reference if (0 === strpos($matches[1], 'http')) { @@ -78,10 +78,11 @@ function ($matches) use (&$brokenRefs) { return; } // Valid class reference - if (class_exists($matches[1]) || interface_exists($matches[1] || trait_exists($matches[1]))) { + if (class_exists($matches[1]) || interface_exists($matches[1]) || trait_exists($matches[1])) { return; } - // Valid method, magic method, andd constant references + + // Valid method, magic method, and constant references if (false !== strpos($matches[1], '::')) { if (false !== strpos($matches[1], '()')) { list($class, $method) = explode('::', str_replace('()', '', $matches[1])); @@ -89,10 +90,12 @@ function ($matches) use (&$brokenRefs) { if (method_exists($class, $method)) { return; } + // Assume it's a magic Async method if ('Async' === substr($method, -5)) { return; } + } elseif (defined($matches[1])) { // Valid constant reference return;