|
66 | 66 | "type ", |
67 | 67 | ) |
68 | 68 |
|
| 69 | + # Remove the replacements below once |
| 70 | + # https://github.com/googleapis/synthtool/pull/1188 is merged |
| 71 | + |
| 72 | + # Update googleapis/repo-automation-bots repo to main in .kokoro/*.sh files |
| 73 | + s.replace( |
| 74 | + ".kokoro/*.sh", |
| 75 | + "repo-automation-bots/tree/master", |
| 76 | + "repo-automation-bots/tree/main", |
| 77 | + ) |
| 78 | + |
| 79 | + # Customize CONTRIBUTING.rst to replace master with main |
| 80 | + s.replace( |
| 81 | + "CONTRIBUTING.rst", |
| 82 | + "fetch and merge changes from upstream into master", |
| 83 | + "fetch and merge changes from upstream into main", |
| 84 | + ) |
| 85 | + |
| 86 | + s.replace( |
| 87 | + "CONTRIBUTING.rst", "git merge upstream/master", "git merge upstream/main", |
| 88 | + ) |
| 89 | + |
| 90 | + s.replace( |
| 91 | + "CONTRIBUTING.rst", |
| 92 | + """export GOOGLE_CLOUD_TESTING_BRANCH=\"master\"""", |
| 93 | + """export GOOGLE_CLOUD_TESTING_BRANCH=\"main\"""", |
| 94 | + ) |
| 95 | + |
| 96 | + s.replace( |
| 97 | + "CONTRIBUTING.rst", r"remote \(``master``\)", "remote (``main``)", |
| 98 | + ) |
| 99 | + |
| 100 | + s.replace( |
| 101 | + "CONTRIBUTING.rst", |
| 102 | + "blob/master/CONTRIBUTING.rst", |
| 103 | + "blob/main/CONTRIBUTING.rst", |
| 104 | + ) |
| 105 | + |
| 106 | + s.replace( |
| 107 | + "CONTRIBUTING.rst", "blob/master/noxfile.py", "blob/main/noxfile.py", |
| 108 | + ) |
| 109 | + |
| 110 | + s.replace( |
| 111 | + "docs/conf.py", "master_doc", "root_doc", |
| 112 | + ) |
| 113 | + |
| 114 | + s.replace( |
| 115 | + "docs/conf.py", |
| 116 | + "# The master toctree document.", |
| 117 | + "# The root toctree document.", |
| 118 | + ) |
| 119 | + |
69 | 120 | s.move( |
70 | 121 | library, |
71 | 122 | excludes=[ |
|
0 commit comments