This is needed because bot_update changed from getting the cache directory from
the global path module to the gclient config.
BUG=589140
Review URL: https://codereview.chromium.org/1768893003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299143 0039d316-1c4b-4281-b951-d872f2087c98
git-cl-try does not properly print error message when the response
status code is 403, because response parsing is broken.
Fix response parsing.
R=sheyang@chromium.org, tandrii@chromium.org
BUG=
Review URL: https://codereview.chromium.org/1773963002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299137 0039d316-1c4b-4281-b951-d872f2087c98
This allows to generate new IDs on the fly without installing
commit-msg hook and works just fine on Windows.
BUG=579183
Review URL: https://codereview.chromium.org/1757133002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299094 0039d316-1c4b-4281-b951-d872f2087c98
This should insert the message according to Gerrit's own commit-msg
hook implementation.
BUG=579183
Review URL: https://codereview.chromium.org/1758943002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299093 0039d316-1c4b-4281-b951-d872f2087c98
The part that runs dartfmt was relying on the part that runs (or not)
Clang to set the |env| local variable, which no longer happens after
https://codereview.chromium.org/1734863002, making `git cl format` fail
with:
Traceback (most recent call last):
File "/usr/local/google/home/ppi/projects/depot_tools/git_cl.py", line 3957, in <module>
sys.exit(main(sys.argv[1:]))
File "/usr/local/google/home/ppi/projects/depot_tools/git_cl.py", line 3939, in main
return dispatcher.execute(OptionParser(), argv)
File "/usr/local/work/depot_tools/subcommand.py", line 252, in execute
return command(parser, args[1:])
File "/usr/local/google/home/ppi/projects/depot_tools/git_cl.py", line 3837, in CMDformat
stdout = RunCommand(command, cwd=top_dir, env=env)
UnboundLocalError: local variable 'env' referenced before assignment
It seems that we don't need to override env for dartfm anyway - the
clang part is doing this to put clang_format_tool in PATH.
This patch just drops env= from RunCommand for dartfmt.
Review URL: https://codereview.chromium.org/1760873002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299072 0039d316-1c4b-4281-b951-d872f2087c98
Sometimes the spec passed in via parameters also have got_revision_mapping that
we want to use.
BUG=590788
Review URL: https://codereview.chromium.org/1748143002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299015 0039d316-1c4b-4281-b951-d872f2087c98
Currently, if git cl format does not find any clang-formattable files,
either in the path provided on the command line or in the CL as a whole,
then it applies clang-format to all changes in the CL. This CL fixes
this by changing git cl format to not clang-format when it does not find
any changed files that are clang-formattable.
Review URL: https://codereview.chromium.org/1734863002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298971 0039d316-1c4b-4281-b951-d872f2087c98
Every time I write a json file, I end up wishing I put my toplevel items
into non-toplevel items down the line when I want to add more stuff to the
json file. Address this now, while no toolchain with this json file has
been built yet.
Follow-up to https://codereview.chromium.org/1706423002/
BUG=495204
Review URL: https://codereview.chromium.org/1718083003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298908 0039d316-1c4b-4281-b951-d872f2087c98
Added --ignore-file argument, so you can specify ignored commits in a
file rather than as raw command-line arguments. Also, automatically
searches for a file called .git-blame-ignore-revs, which is
automatically used as an ignore list by default.
Also, specifying an unknown revision (either on the command line or in a
file) now generates a warning, not an error.
Notes on some decisions:
- The file is called .git-blame-ignore-revs (not mentioning hyper-blame)
because we may use the same list in tools other than hyper-blame in
the future.
- We look at the *currently checked out* version of
.git-blame-ignore-revs (not the version at the specified revision) for
consistency with .git-ignore. Because we only expect revisions to be
added (not deleted), it should be fine to use an ignore list from a
newer version than the revision being blamed.
- We considered using git notes for the ignore list so that you could
add a revision to the ignore list without needing a follow-up CL.
However, there are some problems with this approach. git notes is not
automatically synced with git clone/pull. Also the Chromium infra
tools (Reitveld, CQ) are not set up to allow modification of git
notes, nor are changes to git notes subject to OWNERS checks. Using a
regular file ensures all users synced to a particular revision are
using the same ignore list.
BUG=574290
Review URL: https://codereview.chromium.org/1697423004
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298897 0039d316-1c4b-4281-b951-d872f2087c98
No intended behavior change. This makes it possible to dump this state into
SetEnv.x32.json and SetEnv.x64.json in an easy follow-up.
BUG=495204
Review URL: https://codereview.chromium.org/1708223002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298856 0039d316-1c4b-4281-b951-d872f2087c98
\n doesn't work on Windows, and %B is shorter anyway.
BUG=586344
Review URL: https://codereview.chromium.org/1705193003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298845 0039d316-1c4b-4281-b951-d872f2087c98
With this change, fix_encoding can be imported in python3.
fix_encoding.fix_encoding() returns False because, at least on my Ubuntu 14.04
system running python 3.4.3;
sys.getdefaultencoding() == 'utf-8'
The Windows specific code hasn't been tested on python3 and is expected to
require fixes.
R=vapier@chromium.org
BUG=61357
Review URL: https://codereview.chromium.org/1710553003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298834 0039d316-1c4b-4281-b951-d872f2087c98
This will hopefully make Rietveld._send retry 500s like it promises to
BUG=585632
Review URL: https://codereview.chromium.org/1681333005
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298726 0039d316-1c4b-4281-b951-d872f2087c98