put goma client in depot_tools

install goma client cipd package in depot_tools.

should not use $MYPATH/goma_ctl in cipd_bin_setup
since $MYPATH/goma_ctl uses cipd_bin_setup in itself,
so causing recursive calls.
invoke python to run .cipd/goma_ctl.py in cipd_bin_setup
instead.

Bug: b/77663154
Change-Id: I9f82c766a886a2acfb899e3594e5f05a7b7bc75a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/1866350
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Dirk Pranke <dpranke@chromium.org>
Commit-Queue: Fumitoshi Ukai <ukai@chromium.org>
8 files changed
tree: 1e1f17825901cf5b6fbec37c2498d0c6ab782b18
  1. .gitattributes
  2. .gitignore
  3. .style.yapf
  4. .vpython
  5. .vpython3
  6. CROS_OWNERS
  7. LICENSE
  8. OWNERS
  9. PRESUBMIT.py
  10. README.gclient.md
  11. README.git-cl.md
  12. README.md
  13. annotated_gclient.py
  14. auth.py
  15. autoninja
  16. autoninja.bat
  17. autoninja.py
  18. bb
  19. bb.bat
  20. bootstrap/
  21. bootstrap_python3
  22. breakpad.py
  23. cipd
  24. cipd.bat
  25. cipd.ps1
  26. cipd_bin_setup.bat
  27. cipd_bin_setup.sh
  28. cipd_client_version
  29. cipd_client_version.digests
  30. cipd_manifest.txt
  31. cipd_manifest.versions
  32. cit
  33. cit.bat
  34. cit.py
  35. clang-format
  36. clang-format.bat
  37. clang_format.py
  38. clang_format_merge_driver
  39. clang_format_merge_driver.bat
  40. clang_format_merge_driver.py
  41. codereview.settings
  42. compile_single_file
  43. compile_single_file.bat
  44. compile_single_file.py
  45. cpplint.bat
  46. cpplint.py
  47. cpplint_chromium.py
  48. crosjobs
  49. dart_format.py
  50. detect_host_arch.py
  51. download_from_google_storage
  52. download_from_google_storage.bat
  53. download_from_google_storage.py
  54. ensure_bootstrap
  55. fetch
  56. fetch.bat
  57. fetch.py
  58. fetch_configs/
  59. fix_encoding.py
  60. gclient
  61. gclient-new-workdir.py
  62. gclient.bat
  63. gclient.py
  64. gclient_completion.sh
  65. gclient_eval.py
  66. gclient_paths.py
  67. gclient_scm.py
  68. gclient_utils.py
  69. gerrit_client.py
  70. gerrit_util.py
  71. git-cache
  72. git-cl
  73. git-crrev-parse
  74. git-drover
  75. git-find-releases
  76. git-footers
  77. git-freeze
  78. git-gs
  79. git-hyper-blame
  80. git-map
  81. git-map-branches
  82. git-mark-merge-base
  83. git-nav-downstream
  84. git-nav-upstream
  85. git-new-branch
  86. git-number
  87. git-rebase-update
  88. git-rename-branch
  89. git-reparent-branch
  90. git-retry
  91. git-runhooks
  92. git-squash-branch
  93. git-templates/
  94. git-thaw
  95. git-upstream-diff
  96. git_cache.py
  97. git_cl.py
  98. git_cl_completion.sh
  99. git_common.py
  100. git_dates.py
  101. git_drover.py
  102. git_find_releases.py
  103. git_footers.py
  104. git_freezer.py
  105. git_hyper_blame.py
  106. git_map.py
  107. git_map_branches.py
  108. git_mark_merge_base.py
  109. git_nav_downstream.py
  110. git_new_branch.py
  111. git_number.py
  112. git_rebase_update.py
  113. git_rename_branch.py
  114. git_reparent_branch.py
  115. git_retry.py
  116. git_squash_branch.py
  117. git_upstream_diff.py
  118. gn
  119. gn.bat
  120. gn.py
  121. goma_auth
  122. goma_auth.bat
  123. goma_ctl
  124. goma_ctl.bat
  125. gsutil.py
  126. gsutil.py.bat
  127. gsutil.vpython
  128. infra/
  129. led
  130. led.bat
  131. luci-auth
  132. luci-auth.bat
  133. lucicfg
  134. lucicfg.bat
  135. mac_toolchain
  136. man/
  137. metrics.README.md
  138. metrics.py
  139. metrics_utils.py
  140. my_activity.py
  141. ninja
  142. ninja-linux32
  143. ninja-linux64
  144. ninja-mac
  145. ninja.exe
  146. ninjalog.README.md
  147. ninjalog_uploader.py
  148. ninjalog_uploader_wrapper.py
  149. owners.py
  150. owners_finder.py
  151. post_build_ninja_summary.py
  152. presubmit_canned_checks.py
  153. presubmit_support.py
  154. profile.xml
  155. prpc
  156. prpc.bat
  157. pylint
  158. pylint-1.5
  159. pylint-1.6
  160. pylint-1.7
  161. pylint-1.8
  162. pylint-1.9
  163. pylint.bat
  164. pylint_main.py
  165. pylintrc
  166. python_runner.sh
  167. recipes/
  168. repo
  169. roll-dep
  170. roll-dep-svn
  171. roll-dep-svn.bat
  172. roll-dep.bat
  173. roll_dep.py
  174. roll_dep_svn.py
  175. scm.py
  176. setup_color.py
  177. split_cl.py
  178. subcommand.py
  179. subprocess2.py
  180. support/
  181. testing_support/
  182. tests/
  183. third_party/
  184. update_depot_tools
  185. update_depot_tools.bat
  186. update_depot_tools_toggle.py
  187. upload_metrics.py
  188. upload_to_google_storage.py
  189. vpython
  190. vpython.bat
  191. vpython3
  192. vpython3.bat
  193. watchlists.py
  194. weekly
  195. win_toolchain/
  196. wtf
  197. yapf
  198. yapf.bat
  199. zsh-goodies/
README.md

depot_tools

Tools for working with Chromium development. It requires python 2.7.

Tools

The most important tools are:

  • fetch: A gclient wrapper to checkout a project. Use fetch --help for more details.
  • gclient: A meta-checkout tool. Think repo or git submodules, except that it support OS-specific rules, e.g. do not checkout Windows only dependencies when checking out for Android. Use gclient help for more details and README.gclient.md.
  • git cl: A code review tool to interact with Rietveld or Gerrit. Use git cl help for more details and README.git-cl.md.
  • roll-dep: A gclient dependency management tool to submit a dep roll, updating a dependency to a newer revision.

There are a lot of git utilities included.

Updating

depot_tools updates itself automatically when running gclient tool. To disable auto update, set the environment variable DEPOT_TOOLS_UPDATE=0.

To update package manually, run update_depot_tools.bat on Windows, or ./update_depot_tools on Linux or Mac.

On Windows only, running gclient will install git and python.

Contributing

To contribute change for review:

git new-branch <somename>
# Hack
git add .
git commit -a -m "Fixes goat teleporting"
# find reviewers
git cl owners
git log -- <yourfiles>

# Request a review.
git cl upload -r reviewer1@chromium.org,reviewer2@chromium.org --send-mail

# Edit change description if needed.
git cl desc

# If change is approved, flag it to be committed.
git cl set-commit

# If change needs more work.
git rebase-update
...
git cl upload -t "Fixes goat teleporter destination to be Australia"

See also open bugs, open reviews, forum or report problems.

cpplint.py

Until 2018, our cpplint.py was a copy of the upstream version at https://github.com/google/styleguide/tree/gh-pages/cpplint. Unfortunately, that repository is not maintained any more. If you want to update cpplint.py in depot_tools, just upload a patch to do so. We will figure out a long-term strategy via issue https://crbug.com/916550.

Note that the cpplint.py here is also used by the Tricium analyzer, so if the cpplint.py here changes, we should also update the copy used there.