Skip to content

Commit 5c0fa62

Browse files
authored
chore(python): rename default branch to main (#1188)
* chore(python): rename default branch to main * typo * chore(python): rename master_doc to root_doc
1 parent 3fa141d commit 5c0fa62

4 files changed

Lines changed: 15 additions & 15 deletions

File tree

synthtool/gcp/templates/python_library/.kokoro/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ python3 -m pip install --upgrade --quiet nox
4141
python3 -m nox --version
4242

4343
# If this is a continuous build, send the test log to the FlakyBot.
44-
# See https://github.com/googleapis/repo-automation-bots/tree/master/packages/flakybot.
44+
# See https://github.com/googleapis/repo-automation-bots/tree/main/packages/flakybot.
4545
if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"continuous"* ]]; then
4646
cleanup() {
4747
chmod +x $KOKORO_GFILE_DIR/linux_amd64/flakybot

synthtool/gcp/templates/python_library/.kokoro/test-samples-impl.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ for file in samples/**/requirements.txt; do
8080
EXIT=$?
8181

8282
# If this is a periodic build, send the test log to the FlakyBot.
83-
# See https://github.com/googleapis/repo-automation-bots/tree/master/packages/flakybot.
83+
# See https://github.com/googleapis/repo-automation-bots/tree/main/packages/flakybot.
8484
if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"periodic"* ]]; then
8585
chmod +x $KOKORO_GFILE_DIR/linux_amd64/flakybot
8686
$KOKORO_GFILE_DIR/linux_amd64/flakybot

synthtool/gcp/templates/python_library/CONTRIBUTING.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,9 @@ You'll have to create a development environment using a Git checkout:
5555
# Configure remotes such that you can pull changes from the {{ metadata['repo']['repo'] }}
5656
# repository into your local repository.
5757
$ git remote add upstream [email protected]:{{ metadata['repo']['repo'] }}.git
58-
# fetch and merge changes from upstream into master
58+
# fetch and merge changes from upstream into main
5959
$ git fetch upstream
60-
$ git merge upstream/master
60+
$ git merge upstream/main
6161

6262
Now your local repo is set up such that you will push changes to your GitHub
6363
repo, from which you can submit a pull request.
@@ -115,12 +115,12 @@ Coding Style
115115
variables::
116116

117117
export GOOGLE_CLOUD_TESTING_REMOTE="upstream"
118-
export GOOGLE_CLOUD_TESTING_BRANCH="master"
118+
export GOOGLE_CLOUD_TESTING_BRANCH="main"
119119

120120
By doing this, you are specifying the location of the most up-to-date
121-
version of ``{{ metadata['repo']['repo'].split('/')[1] }}``. The the suggested remote name ``upstream``
122-
should point to the official ``googleapis`` checkout and the
123-
the branch should be the main branch on that remote (``master``).
121+
version of ``{{ metadata['repo']['repo'].split('/')[1] }}``. The
122+
remote name ``upstream`` should point to the official ``googleapis``
123+
checkout and the branch should be the default branch on that remote (``main``).
124124

125125
- This repository contains configuration for the
126126
`pre-commit <https://pre-commit.com/>`__ tool, which automates checking
@@ -219,7 +219,7 @@ The `description on PyPI`_ for the project comes directly from the
219219
``README``. Due to the reStructuredText (``rst``) parser used by
220220
PyPI, relative links which will work on GitHub (e.g. ``CONTRIBUTING.rst``
221221
instead of
222-
``https://github.com/{{ metadata['repo']['repo']}}/blob/master/CONTRIBUTING.rst``)
222+
``https://github.com/{{ metadata['repo']['repo']}}/blob/main/CONTRIBUTING.rst``)
223223
may cause problems creating links or rendering the description.
224224

225225
.. _description on PyPI: https://pypi.org/project/{{ metadata['repo']['distribution_name']}}
@@ -240,7 +240,7 @@ We support:
240240

241241
Supported versions can be found in our ``noxfile.py`` `config`_.
242242

243-
.. _config: https://github.com/{{ metadata['repo']['repo'] }}/blob/master/noxfile.py
243+
.. _config: https://github.com/{{ metadata['repo']['repo'] }}/blob/main/noxfile.py
244244

245245

246246
We also explicitly decided to support Python 3 beginning with version {{ unit_test_python_versions | first }}.

synthtool/gcp/templates/python_library/docs/conf.py.j2

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ source_suffix = [".rst", ".md"]
7676
# The encoding of source files.
7777
# source_encoding = 'utf-8-sig'
7878

79-
# The master toctree document.
80-
master_doc = "index"
79+
# The root toctree document.
80+
root_doc = "index"
8181

8282
# General information about the project.
8383
project = "{{ metadata['repo']['distribution_name'] }}"
@@ -280,7 +280,7 @@ latex_elements = {
280280
# author, documentclass [howto, manual, or own class]).
281281
latex_documents = [
282282
(
283-
master_doc,
283+
root_doc,
284284
"{{ metadata['repo']['distribution_name'] }}.tex",
285285
"{{ metadata['repo']['distribution_name'] }} Documentation",
286286
author,
@@ -315,7 +315,7 @@ latex_documents = [
315315
# (source start file, name, description, authors, manual section).
316316
man_pages = [
317317
(
318-
master_doc,
318+
root_doc,
319319
"{{ metadata['repo']['distribution_name'] }}",
320320
"{{ metadata['repo']['distribution_name'] }} Documentation",
321321
[author],
@@ -334,7 +334,7 @@ man_pages = [
334334
# dir menu entry, description, category)
335335
texinfo_documents = [
336336
(
337-
master_doc,
337+
root_doc,
338338
"{{ metadata['repo']['distribution_name'] }}",
339339
"{{ metadata['repo']['distribution_name'] }} Documentation",
340340
author,

0 commit comments

Comments
 (0)