From 8a27ba04c5e117ce96a962313d88acf7e8e07de5 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Thu, 2 Sep 2021 16:54:03 -0400 Subject: [PATCH] chore(python): rename default branch to main (#25) * chore(python): rename default branch to main Source-Link: https://github.com/googleapis/synthtool/commit/5c0fa62eea9c33ebe61e582424b659eb264e1ba4 Post-Processor: gcr.io/repo-automation-bots/owlbot-python:latest@sha256:0ffe3bdd6c7159692df5f7744da74e5ef19966288a6bf76023e8e04e0c424d7d * chore: remove obsolete replacements in owlbot.py Co-authored-by: Owl Bot Co-authored-by: Anthonios Partheniou --- .../.github/.OwlBot.lock.yaml | 2 +- .../google-cloud-datastream/CONTRIBUTING.rst | 6 +-- packages/google-cloud-datastream/docs/conf.py | 10 ++--- packages/google-cloud-datastream/owlbot.py | 44 +------------------ 4 files changed, 11 insertions(+), 51 deletions(-) diff --git a/packages/google-cloud-datastream/.github/.OwlBot.lock.yaml b/packages/google-cloud-datastream/.github/.OwlBot.lock.yaml index ef3cb34f66fd..c07f148f0b0b 100644 --- a/packages/google-cloud-datastream/.github/.OwlBot.lock.yaml +++ b/packages/google-cloud-datastream/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/repo-automation-bots/owlbot-python:latest - digest: sha256:1456ea2b3b523ccff5e13030acef56d1de28f21249c62aa0f196265880338fa7 + digest: sha256:0ffe3bdd6c7159692df5f7744da74e5ef19966288a6bf76023e8e04e0c424d7d diff --git a/packages/google-cloud-datastream/CONTRIBUTING.rst b/packages/google-cloud-datastream/CONTRIBUTING.rst index c5860ead37ba..ecbbbe7b696e 100644 --- a/packages/google-cloud-datastream/CONTRIBUTING.rst +++ b/packages/google-cloud-datastream/CONTRIBUTING.rst @@ -113,9 +113,9 @@ Coding Style export GOOGLE_CLOUD_TESTING_BRANCH="main" By doing this, you are specifying the location of the most up-to-date - version of ``python-datastream``. The the suggested remote name ``upstream`` - should point to the official ``googleapis`` checkout and the - the branch should be the main branch on that remote (``main``). + version of ``python-datastream``. The + remote name ``upstream`` should point to the official ``googleapis`` + checkout and the branch should be the default branch on that remote (``main``). - This repository contains configuration for the `pre-commit `__ tool, which automates checking diff --git a/packages/google-cloud-datastream/docs/conf.py b/packages/google-cloud-datastream/docs/conf.py index c59dd39daa25..17393f025590 100644 --- a/packages/google-cloud-datastream/docs/conf.py +++ b/packages/google-cloud-datastream/docs/conf.py @@ -76,8 +76,8 @@ # The encoding of source files. # source_encoding = 'utf-8-sig' -# The master toctree document. -master_doc = "index" +# The root toctree document. +root_doc = "index" # General information about the project. project = "google-cloud-datastream" @@ -280,7 +280,7 @@ # author, documentclass [howto, manual, or own class]). latex_documents = [ ( - master_doc, + root_doc, "google-cloud-datastream.tex", "google-cloud-datastream Documentation", author, @@ -315,7 +315,7 @@ # (source start file, name, description, authors, manual section). man_pages = [ ( - master_doc, + root_doc, "google-cloud-datastream", "google-cloud-datastream Documentation", [author], @@ -334,7 +334,7 @@ # dir menu entry, description, category) texinfo_documents = [ ( - master_doc, + root_doc, "google-cloud-datastream", "google-cloud-datastream Documentation", author, diff --git a/packages/google-cloud-datastream/owlbot.py b/packages/google-cloud-datastream/owlbot.py index de411092baff..af3d93272618 100644 --- a/packages/google-cloud-datastream/owlbot.py +++ b/packages/google-cloud-datastream/owlbot.py @@ -31,50 +31,10 @@ # ---------------------------------------------------------------------------- templated_files = gcp.CommonTemplates().py_library(microgenerator=True) -python.py_samples(skip_readmes=True) -s.move(templated_files, excludes=[".coveragerc"]) # the microgenerator has a good coveragerc file - -# Remove the replacements below once https://github.com/googleapis/synthtool/pull/1188 is merged - -# Update googleapis/repo-automation-bots repo to main in .kokoro/*.sh files -s.replace(".kokoro/*.sh", "repo-automation-bots/tree/master", "repo-automation-bots/tree/main") - -# Customize CONTRIBUTING.rst to replace master with main -s.replace( - "CONTRIBUTING.rst", - "fetch and merge changes from upstream into master", - "fetch and merge changes from upstream into main", -) -s.replace( - "CONTRIBUTING.rst", - "git merge upstream/master", - "git merge upstream/main", -) - -s.replace( - "CONTRIBUTING.rst", - """export GOOGLE_CLOUD_TESTING_BRANCH=\"master\"""", - """export GOOGLE_CLOUD_TESTING_BRANCH=\"main\"""", -) - -s.replace( - "CONTRIBUTING.rst", - "remote \(``master``\)", - "remote (``main``)", -) - -s.replace( - "CONTRIBUTING.rst", - "blob/master/CONTRIBUTING.rst", - "blob/main/CONTRIBUTING.rst", -) +s.move(templated_files, excludes=[".coveragerc"]) # the microgenerator has a good coveragerc file -s.replace( - "CONTRIBUTING.rst", - "blob/master/noxfile.py", - "blob/main/noxfile.py", -) +python.py_samples(skip_readmes=True) # ---------------------------------------------------------------------------- # Run blacken session