Commit Graph

890 Commits (375765c6bf8081b53669293f6d1d4c71f67ffcb0)

Author SHA1 Message Date
dsansome@chromium.org f4ef3e70dd Retry socket.timeout as well as SSL timeouts (ssl.SSLError is a subclass of socket.error).
To fix this flake:
https://uberchromegw.corp.google.com/i/internal.infra.try/builders/infra-internal-presubmit/builds/1216/steps/bot_update/logs/stdio

BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@297234 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
dbeam@chromium.org 5a2af6d9d1 Add long line exception for GEN('#include') in JS browser tests.
It's basically like C++'s #include but in JS.

Why write 1 language when you can write 2?!

R=maruel@chromium.org
BUG=540977

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@297065 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
sammc@chromium.org 900a33fb4d Add a git-drover.
This uses the same trick as git-new-workdir to reuse an existing git
checkout without interfering with it. However, this makes it only usable
on platforms where os.symlink exists.

BUG=404755

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296920 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
szager@chromium.org 66c8b850e4 Allow 'git cache fetch' to re-bootstrap.
With this change, 'git cache fetch' will automatically re-bootstrap
a repo from google storage if the local cache has too many pack
files.  The behavior can be disabled with the --no-bootstrap flag.

BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296829 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
dnj@chromium.org 605d81dfb3 gsutil: Parallel-safe, specify target, add clean.
- Update "gsutil.py" to be cooperatively safe when invoked
  multiple times simultaneously.
- Allow the cache directory to be overridden by the
  DEPOT_TOOLS_GSUTIL_BIN_DIR environment variable.
- Add a "--clean" flag to force "gsutil.py" to do a clean download.

BUG=chromium:452497
TEST=local
  - for i in `seq 1 50`; do ./gsutil.py --clean -- version&; done

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296772 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
stip@chromium.org 74374f985f Add a --keep-going flag for people who run rebase-update infrequently.
Review URL: https://codereview.chromium.org/1331263002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296639 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
ricow@chromium.org 92cd7b05d5 Reland 0c7d94eb9d9fa388bda0d74405c0928dceea22ff: Add support for tar.gz archive files to download from download_from_google_storage
I fixed the overlapping argument and fixed up the tests so that the actual sha1 hash is now passed (since the tool actually check now that the downloaded file hash matches)

BUG=
R=hinoka@google.com

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296346 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
tandrii@chromium.org 41a9ce45ee Fail with user friendly error when no new parent branch is specified.
Before this change, running
$ git reparent-branch
produced stacktrace and
"TypeError: sequence item 4: expected string, NoneType found"

R=iannucci@chromium.org
TEST=manual + unittest + coverage.
BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296235 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
dpranke@chromium.org ee87f587ea Make 'git cl status' report the current branch even if there's no active CL.
TBR=ianh@google.com

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296187 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
hinoka@chromium.org be46fddf5f Add verification to downloaded files
This does one last check to see if the file downloaded by
download_from_google_storage.py actually matches its sha1

BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296155 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
sergiyb@chromium.org 4b39c5fe44 Add a space before period in review URL
This is needed to ensure that it resolves to a correct URL on Gitiles.

R=maruel@chromium.org, smut@google.com

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295932 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
iannucci@chromium.org d61a4950b2 Changes to improve multiprocessing PRESUBMIT support in Windows
* make RunTest's multiprocessing.Pool in the constructor of InputApi
    to avoid getting tripped up by chdir manipulation.
  * Don't do the split cyclic-import check when the invoker of the
    Pylint presubmit checks explicitly sends cyclic import check
    parameters via extra_args
  * fix pseudobug where ownership of the files variable was unclear,
    and pass all arguments on stdin (instead of mix of CLI + stdin).
  * fix bug in pylint which caused it to manipulate sys.path before
    spawning its subprocesses, which caused multiprocessing to fail
    on windows.
    * Note: This may carry a slight semantic change. Before, pylint would
      add all .py files' directories to sys.path while checking any of
      them. Now in parallel mode, pylint will only add the path of the
      single file to sys.path. This behavior actually mirrors Python's
      own behavior, so the check should be more-correct than before (and
      should cut down on pylint import scanning time with very large
      sys.path's).
    * If someone encounters an issue with this, please note that the
      GetPylint check also includes an extra_paths_list which is
      expressly for this purpose.

R=dpranke@chromium.org, kbr@chromium.org, maruel@chromium.org
BUG=501012

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295908 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
boliu@chromium.org 2aa134c40a Revert of Add support for tar.gz archive files to download from download_from_google_storage (patchset #8 id:140001 of https://codereview.chromium.org/807463005/)
Reason for revert:
This conflicts with (and duplicates?) the -z option below and has broken one of the chrome android downstream bots.

Safer to revert than trying to fix

Original issue's description:
> Add support for tar.gz archive files to download from download_from_google_storage
> 
> Also, add support for directly setting the public read flag on uploaded files.
> 
> The support for tar.gz allows the uploaded bundle to be a single tar.gz file instead of a lot of individual files using the directory support already in. The benefit here is that it is much easier to update the dependency. Simply clean out the existing files, copy in the new ones, create a tar.gz file, with the same name as the directory + 'tar.gz'. If the directory name and file name does not match up we will not clean up existing artifacts on download (i.e., there can be left over files after extracting).
> 
> I am doing this because I am moving a bunch of the dart dependencies to gcs, and a lot of our dependencies is much easier to manage with this in. If you don't like this, I can simply wrap the download script in another python script and do the logic there, but this may be handy for other people as well.
> 
> Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=295872

TBR=hinoka@google.com,hinoka@chromium.org,azarchs@chromium.org,ricow@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295883 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
ricow@google.com 0c7d94eb9d Add support for tar.gz archive files to download from download_from_google_storage
Also, add support for directly setting the public read flag on uploaded files.

The support for tar.gz allows the uploaded bundle to be a single tar.gz file instead of a lot of individual files using the directory support already in. The benefit here is that it is much easier to update the dependency. Simply clean out the existing files, copy in the new ones, create a tar.gz file, with the same name as the directory + 'tar.gz'. If the directory name and file name does not match up we will not clean up existing artifacts on download (i.e., there can be left over files after extracting).

I am doing this because I am moving a bunch of the dart dependencies to gcs, and a lot of our dependencies is much easier to manage with this in. If you don't like this, I can simply wrap the download script in another python script and do the logic there, but this may be handy for other people as well.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295872 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
raphael.kubo.da.costa@intel.com 58d05b0892 Unskip testGetBranchesInfo().
It is not clear why it was skipped in r293502, but it was problematic
before that as it can be seen from CL 802403003.

The reason for the different results (and likely the reason why the test
was skipped) is that the handling of the %(upstream:track) and
%(upstream:trackhort) formatting tags was broken in git itself until
version 2.3.0. This was fixed in git commit b6160d95, and the fix shows
that the test expectations in testGetBranchesInfo() were actually wrong
in one of the cases.

Fix the expectations and make sure we only use %(upstream:track) in the
test when a suitable git version is present.

R=pgervais@chromium.org,iannucci@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295814 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
iannucci@chromium.org 1b9a55600f Fix depot_tools presubmit tests by mocking multiprocessing.cpu_count.
R=thakis@chromium.org
BUG=503462

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295795 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
rmistry@google.com 2dd9986270 [depot_tools] New "git cl upload" flag to traverse dependent branches and re-upload them.
Motivation:
The conversation in https://docs.google.com/document/d/1KZGFKZpOPvco81sYVRCzwlnjGctup71RAzY0MSb0ntc/edit?disco=AAAAAXU60E8

BUG=502257

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295779 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
ricow@google.com 2911a38229 Fix test expectations for download_from_google_storage_unittests.py
This does not seem to be run by the bots, otherwise they should be red

R=hinoka@google.com, iannucci@google.com
BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295741 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
iannucci@chromium.org 0af3bb37eb Parallelize pylint PRESUBMIT checks.
R=maruel@chromium.org
BUG=479837,499650

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295664 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
pgervais@chromium.org 8ba38ff4dc Added message when upstream branch is gone.
BUG=496892

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295634 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
tandrii@chromium.org 6c14310ef8 Make git auto-svn fail if git svn fetch fails.
R=agable@chromium.org
BUG=437397

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295630 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
akuegel@chromium.org 58888e1171 Fix git branch parsing.
In git version 2.4 the git branch command prints "* (HEAD detached at"
or "* (HEAD detached from" instead of "* (detached from". Adjust the parsing to make our tests
still work with git 2.4.

BUG=487172

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295578 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
smut@google.com 4c61dccd9d Add period below review URL when adding review URL footer to committed CLs
Because some interfaces aren't linkifying the URL when the commit message ends with it.

BUG=480922
TESTED=tests/git_cl_test.py; presubmit ok

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295566 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
akuegel@chromium.org 4c10d415d9 Fix push_basic.sh
This CL changes the check for base URL to a query to the json endpoint.
This makes the test pass on the trybot.

BUG=353718

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295538 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
sbc@chromium.org 217330f2f0 Add quotes around command line in subproccess error message
Allows the command line itself to be distinguished
from the surrounding error message.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295481 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
wychen@chromium.org 5b3bebb18e In PatchIssue, add CL description to commit message
Before this change, the commit message only contains issue number and
patchset number. Adding CL description should be more informative.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295449 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
maruel@chromium.org dbd102dc2b Remove most svn related testing.
Subversion usage is going away, tests get the kick first.

R=iannucci@chromium.org
BUG=475320

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295411 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
akuegel@chromium.org a1bf72dd1e Disable tests that break because of git 2.4
BUG=487172

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295375 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
luqui@chromium.org 609f395e7c Make git cl upload correctly track upstream refs when uploading to Gerrit
NOPRESUBMIT because it's broke on CQ, Cf. https://codereview.chromium.org/1124803002

BUG=478260
NOPRESUBMIT=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295124 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
wychen@chromium.org a872e757cb Don't clean up after conflict in "git cl patch"
After crrev.com/896453002, if "git cl diff" ends up having conflict, it
would be cleaned up. However, if "git cl patch" ends up with conflict,
the user should still be able to manually resolve them.

BUG=438362
TEST=tests/git_cl_test.py

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295051 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
wychen@chromium.org 445c896d9f Fix mock restoration in git_cl_test
The assertion in TestGitCl.tearDown should be done after super.tearDown
is finished. Otherwise if the assertion fails, mocked objects won't be
restored properly, and the next TestCase would be affected.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295049 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
sergiyb@google.com 7676cca756 Disabled flaky depot_tools tests
R=akuegel@chromium.org,pgervais@chromium.org
BUG=477454

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@295007 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
vadimsh@chromium.org 19f3fe60b2 Enable OAuth2 by default.
ClientLogin will be supposedly turned off on Apr 20.

R=maruel@chromium.org
BUG=356813

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294899 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
vadimsh@chromium.org 24daf9e974 Add support for externally provided refresh tokens.
OAuth token cache file (as implemented by oauth2client library) stores refresh
token and can in theory be deployed via Puppet as the credential. But it is
mutated by the library (to store access tokens, rotated each hour), and so it is
not static and managing it via Puppet (or however else) is a big pain.

Instead, now depot_tools accepts --auth-refresh-token-json parameter with a path
to a static JSON file (with minimal body being {"refresh_token": "....."}). It
can be used to pass previously prepared refresh tokens of role accounts. It
will be used for blink DEPS roller account and similar @chromium.org accounts.

R=maruel@chromium.org
BUG=356813

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294870 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
peter@chromium.org 2ce13130dd Implement support for file: includes in OWNERS files.
This CL implements support for file: include lines in OWNERS files,
both as top-level directives and as per-file directives. The
paths can be either relative or absolute.

Examples of lines in OWNERS files:

  file:test/OWNERS  (relative, top-level)
  file://content/OWNERS  (absolute, top-level)
  per-file mock_impl.h=file:test/OWNERS  (relative, per-file)
  per-file mock_impl.h=file://content/OWNERS  (absolute, per-file)

A whole series of tests to cover this feature have been added
to owners_unittest.py as well.

BUG=119396, 147633

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294854 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
rmistry@google.com 5fc6c8c0e7 Skip OWNERS checks for CQ dry runs
The CQ dry run feature was announced in https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/G5-X0_tfmok

The primary complain is that the presubmit builders fail because of OWNERS checks or because of "Missing LGTM from someone other than...".
This change skips those checks for dry runs.

BUG=chromium:477190

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294853 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
akuegel@chromium.org 5df79ca431 Fix git_cl_tests.
BUG=356813

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294777 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
vadimsh@chromium.org eed4df3d91 Add OAuth2 support for end users (i.e. 3-legged flow with the browser).
This CL introduces new top level command for managing cached auth tokens:
  $ depot-tools-auth login codereview.chromium.org
  $ depot-tools-auth info codereview.chromium.org
  $ depot-tools-auth logout codereview.chromium.org

All scripts that use rietveld.Rietveld internally should be able to use cached
credentials created by 'depot-tools-auth' subcommand. Also 'depot-tools-auth'
is the only way to run login flow. If some scripts stumbles over expired or
revoked token, it dies with the error, asking user to run
'depot-tools-auth login <hostname>'.

Password login is still default. OAuth2 can be enabled by passing --oauth2 to
all scripts.

R=maruel@chromium.org
BUG=356813

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294764 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
vadimsh@chromium.org cf6a5d2026 Extract authentication options handling into a separate function.
It is done in preparation for switching to OAuth2 as default (and only)
authentication method. Having all auth options handled by the same code makes it
easier to gradually add OAuth2 support.

As part of this, some options that would no longer work with OAuth2 (and that
are not being used from anywhere now, as far as I can tell) are removed:
  * Passing account password for authentication via command line.
  * Overriding 'Host' header when making requests to Rietveld (won't work with
    SSL anyway).
  * --account_type option (seems to be ClientLogin specific).

R=maruel@chromium.org
BUG=356813

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294746 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
sbc@chromium.org 71437c0ba5 git-squash-branch: handle empty squashes
Error out of the current tree is dirty (previously the dirty
content would be incorporated silently into the newly
squashed branch!).

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294744 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
pasko@chromium.org 364876e580 In upload_to_google_storage, pass -z argument through to gsutil.
Also fix some latent bugs in the unit tests.

(cherry-picked by pasko@ from https://codereview.chromium.org/1048103002/)

BUG=467005

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294674 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
dtu@chromium.org 03f0c53648 Remove 150% hard line length limit for long URLs.
BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294600 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
rmistry@google.com c68112d9cb Stop defaulting unrecognized branches to master except for handful of special refs.
Context:
In https://codereview.chromium.org/781523002/ I added the ability for target_ref to be set to any branch name. Eg: For Skia a ref of 'refs/remotes/origin/chrome/m42' would be correctly set to 'refs/heads/chrome/m42'.

But in https://codereview.chromium.org/822503005/ this was changed to treat any branch that did not start with 'refs/remotes/branch-heads' or 'refs/remotes/origin/refs' to be 'refs/remotes/origin/master'.
This makes it very chromium specific, there are plenty of other projects that use depot_tools that does not work like this.
For Skia 'refs/remotes/origin/chrome/m42' would now change to 'refs/remotes/origin/master' which is wrong.

The default behavior should be to preserve the original ref not to override it to master.

I handled 'lkgr' and 'lkcr' as special cases in this CL because many developers track it and would like it to land in master by default.

BUG=chromium:463109
NOPRESUBMIT=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294303 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
sbc@chromium.org 013731e832 Handle KeyboardInterrupt consistently in python scripts
Handle KeyboardInterrupt gracefully rather the printing a
backtrace. Most users of these tools don't expect a
backtrace when then hit Ctrl-C.

Also, fix a few other inconsistencies found in the python
startup code of these different scripts:
- always call main function 'main' (rather than 'Main')
- always return 0 from main function
- if main takes args never include argv[0]

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294250 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
rmistry@google.com 5626a92eec Add ability to specify and run post upload hooks.
Motivation: There are a few things we want to do in Skia infrastructure that is not possible to do without this functionality.
Eg1: If there is a change made to Skia's markdown then automatically include a 'DOCS_PREVIEW_URL=https://skia.org?cl=1234' in the CL's description.
Eg2: Automatically add 'NOTRY=true' for changes impacting things that do not need trybot runs.
Eg3: Include CL specific links to skia's perf (https://perf.skia.org/) and correctness (https://gold.skia.org/) servers.

BUG=chromium:462208

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294242 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
dnj@chromium.org 5b23e871ba gclient: Add '--auto_rebase' sync option.
This adds the '--auto_rebase' sync option, enabling parallel updates to
automatically rebase local Git branches during sync.

BUG=None
TEST=local

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294151 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
glider@chromium.org c3617f3fdd Remove the Singleton<T> presubmit check from presubmit_canned_checks.py
This check is specific to Chromium codebase, there's no point in having it in depot_tools.

BUG=None
R=maruel@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294124 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
primiano@chromium.org 1c1273893e Reland "Make gclient ready for the Blink (DEPS to main project)"
Reland crrev.com/743083002, which was reverted in crrev.com/796053002
due to some test flakiness, probably related with an old version of Git on
the bots. Relanding now that the infra has been updated to Trusty (plus
adding some de-flake precautions).

Original CL Description:
Make gclient ready for the Blink (DEPS to main project) transition

This CL makes gclient understand correctly whether a git project is
being moved from DEPS to an upper project and vice-versa.
The driving use case for this is the upcoming Blink merge, where
third_party/Webkit will be removed from DEPS (and .gitignore) and will
become part of the main project.

At present state, gclient leaves the .git folder around when a project
is removed from DEPS, and that causes many problems.

Furthermore this CL solves the performance problem of bisecting across
the merge point. The subproject's (Blink) .git/ folder is moved to a
backup location (in the main checkout root) and is restored when moving
backwards, avoiding a re-fetch when bisecting across the merge point.

BUG=431469

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294082 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
bauerb@chromium.org 27386ddd72 Add a --squash option to Gerrit uploads.
This makes uploading to Gerrit with `git cl` more similar to uploading to Rietveld, by uploading a squashed commit containing the diff to the newest common ancestor.

Uploaded commits are stored in refs/heads/git_cl_uploads/<branch> (and their commit message is used for the squash commit), which allows amending the commit message to change it on the uploaded CL, and looking through the reflog to find old uploaded versions.

BUG=none

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294077 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
wychen@chromium.org b244351f18 The original assertions trigger pylint unreachable warnings, and they are replaced by fail() calls.
Review URL: https://codereview.chromium.org/899503003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293930 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago