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
This will hopefully make Rietveld._send retry 500s like it promises to
BUG=
Review URL: https://codereview.chromium.org/1683603002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298688 0039d316-1c4b-4281-b951-d872f2087c98
rogerta@ has indicated that he should no longer be an owner of
depot_tools.
Review URL: https://codereview.chromium.org/1673313006
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298683 0039d316-1c4b-4281-b951-d872f2087c98
The vs_files directory is used for VS 2015 builds and needs to be in
.gitignore, along with vs2013_files.
The naming convention for timestamps is changed and .gitignore needs to
be updated for that.
Finally, the .pylint.d directory keeps being created and should be
ignored.
Review URL: https://codereview.chromium.org/1667853004
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298682 0039d316-1c4b-4281-b951-d872f2087c98
The UCRT is now optional and it failed to install on one builder.
Making optional to fix build break
If this doesn't fix the break on the waterfall then the switch
to VS 2015 will need to be reverted (crrev.com/1598493004).
TBR=scottmg@chromium.org
BUG=440500
Review URL: https://codereview.chromium.org/1680433002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298634 0039d316-1c4b-4281-b951-d872f2087c98
In C++11 std::swap was moved from <algorithm> to <utility>. As such,
lint needed to be updated to look for/suggest <utility> when it finds
std::swap. The IWYU logic is a little bit different for <utility>
functions, including swap, because they do not typically include
template parameters, unlike most other std:: functions. Reworked the
existing algorithm pattern to be more generic and support multiple
differet headers. Did not rename/all caps _re_pattern_templates as it
is referenced/modified outside of cpplint.py.
BUG=584689
Review URL: https://codereview.chromium.org/1673543004
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298622 0039d316-1c4b-4281-b951-d872f2087c98