Disallow applying patches when git tree is dirty

This allows proper clean-up after failing to apply a patch. Therefore,
if "git cl diff" ends up having conflict, it could be cleaned up.

BUG=438362

Review URL: https://codereview.chromium.org/896453002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294679 0039d316-1c4b-4281-b951-d872f2087c98
1 file changed
tree: b6669c8865a503ded534c5f5424be0c4164dafc5
  1. bootstrap/
  2. git-templates/
  3. git_utils/
  4. man/
  5. recipes/
  6. support/
  7. testing_support/
  8. tests/
  9. third_party/
  10. win_toolchain/
  11. zsh-goodies/
  12. .gitignore
  13. annotated_gclient.py
  14. apply_issue
  15. apply_issue.bat
  16. apply_issue.py
  17. breakpad.py
  18. checkout.py
  19. chrome-update-create-task.bat
  20. chrome-update.bat
  21. chrome-update.py
  22. clang-format
  23. clang-format.bat
  24. clang_format.py
  25. codereview.settings
  26. commit_queue.py
  27. cpplint.bat
  28. cpplint.py
  29. cpplint_chromium.py
  30. create-chromium-git-src
  31. create-ntfs-junction.c
  32. create-ntfs-junction.exe
  33. dart_format.py
  34. download_from_google_storage
  35. download_from_google_storage.bat
  36. download_from_google_storage.py
  37. drover
  38. drover.bat
  39. drover.py
  40. fetch
  41. fetch.bat
  42. fetch.py
  43. fix_encoding.py
  44. gcl
  45. gcl.bat
  46. gcl.py
  47. gclient
  48. gclient-new-workdir.py
  49. gclient.bat
  50. gclient.py
  51. gclient_completion.sh
  52. gclient_scm.py
  53. gclient_utils.py
  54. gerrit_util.py
  55. git-auto-svn
  56. git-cache
  57. git-cherry-pick-upload
  58. git-cl
  59. git-cl-upload-hook
  60. git-crrev-parse
  61. git-crsync
  62. git-crup
  63. git-footers
  64. git-freeze
  65. git-gs
  66. git-lkgr
  67. git-map
  68. git-map-branches
  69. git-mark-merge-base
  70. git-nav-downstream
  71. git-nav-upstream
  72. git-new-branch
  73. git-number
  74. git-rebase-update
  75. git-rename-branch
  76. git-reparent-branch
  77. git-retry
  78. git-runhooks
  79. git-squash-branch
  80. git-thaw
  81. git-try
  82. git-upstream-diff
  83. git_auto_svn.py
  84. git_cache.py
  85. git_cherry_pick_upload.py
  86. git_cl.py
  87. git_common.py
  88. git_footers.py
  89. git_freezer.py
  90. git_map.py
  91. git_map_branches.py
  92. git_mark_merge_base.py
  93. git_nav_downstream.py
  94. git_new_branch.py
  95. git_number.py
  96. git_rebase_update.py
  97. git_rename_branch.py
  98. git_reparent_branch.py
  99. git_retry.py
  100. git_squash_branch.py
  101. git_try.py
  102. git_upstream_diff.py
  103. gn
  104. gn.bat
  105. gn.py
  106. gsutil.py
  107. hammer
  108. hammer.bat
  109. LICENSE
  110. my_activity.py
  111. my_reviews.py
  112. ninja
  113. ninja-linux32
  114. ninja-linux64
  115. ninja-mac
  116. ninja.exe
  117. OWNERS
  118. owners.py
  119. owners_finder.py
  120. patch.py
  121. PRESUBMIT.py
  122. presubmit_canned_checks.py
  123. presubmit_support.py
  124. profile.xml
  125. pylint
  126. pylint.py
  127. pylintrc
  128. python_git_runner.sh
  129. README
  130. README.codereview
  131. README.gclient
  132. README.git-cl
  133. README.testing
  134. repo
  135. rietveld.py
  136. roll-dep
  137. roll-dep.bat
  138. roll_dep.py
  139. scm.py
  140. subcommand.py
  141. subprocess2.py
  142. trychange.py
  143. update_depot_tools
  144. update_depot_tools.bat
  145. upload_to_google_storage.py
  146. WATCHLISTS
  147. watchlists.py
  148. weekly
  149. wtf