Commit Graph

38 Commits (cf6a5d2026479506b24d46d0325931330ebf7b78)

Author SHA1 Message Date
pkasting@chromium.org 884b52c122 Use grep -e --force instead of grep "--force" since apparently the latter doesn't work properly in all cases.
BUG=441072
TEST=No errors from gclient :/

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293380 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
pkasting@chromium.org 7f2720b72a Avoid =~ since msysgit bash doesn't support it.
This uses grep instead.  Note that just grepping for "--force" matches other
things, e.g. "foo--force--foo", but that's a problem with the original code as
well, I think.

BUG=435729
TEST=Run gclient under msysgit bash.  No error should occur.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293340 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
agable@chromium.org 69b67588c4 Run "svn revert" in update_depot_tools --force
R=iannucci@chromium.org, szager@chromium.org, pdr@chromium.org
BUG=435729

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293112 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
szager@chromium.org 83f4767a60 Update to git-1.9.0.
Also, allow multiple git installations to exist side-by-side.
This makes it easier to revert back to an old version quickly.

BUG=
R=maruel@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@258058 0039d316-1c4b-4281-b951-d872f2087c98
11 years ago
mmoss@chromium.org 3b16a28565 More fixes for hardcoded git directory paths.
The git path is based on the git version, so it might change whenever git is
updated. Run git.bat instead, since that's updated with new git installs and
should always point to the right path.

The mingw logic is based on similar handling of python.bat in git-cl.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@252584 0039d316-1c4b-4281-b951-d872f2087c98
11 years ago
pkasting@chromium.org 682d0d7378 Update update_depot_tools to always check out Windows tools on Cygwin.
This is necessary so that Cygwin users have a python directory in depot_tools/,
which will soon be used by gyp_chromium.

BUG=335180

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@245704 0039d316-1c4b-4281-b951-d872f2087c98
11 years ago
rnk@chromium.org 6911307d2d Revert of Fetch Windows tools on Cygwin and use that Python for some scripts (https://codereview.chromium.org/140843004/)
Reason for revert:
This broke auto-updating depot_tools on Cygwin due to use of exec

Original issue's description:
> Fetch Windows tools on Cygwin and use that Python for some scripts
> 
> Tested by running gclient sync a couple of times from a Cygwin shell.
> 
> R=dpranke@chromium.org
> CC=scottmg@chromium.org,thakis@chromium.org,maruel@chromium.org
> BUG=335180
> 
> Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=245315

TBR=dpranke@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=335180

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@245330 0039d316-1c4b-4281-b951-d872f2087c98
11 years ago
rnk@chromium.org a957e27dc1 Fetch Windows tools on Cygwin and use that Python for some scripts
Tested by running gclient sync a couple of times from a Cygwin shell.

R=dpranke@chromium.org
CC=scottmg@chromium.org,thakis@chromium.org,maruel@chromium.org
BUG=335180

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@245315 0039d316-1c4b-4281-b951-d872f2087c98
11 years ago
stuart@fivemicro.com 4fa02461be Don't update git url if 'read' times out
Previous code checked the exit status of 'echo' instead of 'read' to
determine if the 'read' command had timed out.

TEST=Create a mirror of depot_tools.git, git clone it, then run
./update_depot_tools, see prompt for changing the URL, wait at
least 60 seconds and verify that you get the timeout message.

R=maruel@chromium.org
BUG=

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@227427 0039d316-1c4b-4281-b951-d872f2087c98
12 years ago
szager@chromium.org 08c772323f Point to newer git-1.8.0_bin directory.
BUG=169945


Review URL: https://chromiumcodereview.appspot.com/12047061

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@178430 0039d316-1c4b-4281-b951-d872f2087c98
12 years ago
szager@chromium.org 9f36c3891b Add prompt for updating remote URL to git-on-borg.
Review URL: https://codereview.chromium.org/11778024

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@175419 0039d316-1c4b-4281-b951-d872f2087c98
12 years ago
szager@chromium.org 143c3ffe54 For git checkouts of depot_tools, update remote.origin.url to the git-on-borg mirror.
BUG=168205


Review URL: https://chromiumcodereview.appspot.com/11742032

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@175040 0039d316-1c4b-4281-b951-d872f2087c98
12 years ago
newt@chromium.org 9f9aba13b9 Fix usage of bash builtin "local" in update_depot_tools.
The bash command "local myvar=$(mycommand)" has the exit status of the
bash builtin "local" rather than the exit status of mycommand.  To get
the exit status of mycommand, "local myvar" should be run separately
on a previous line.


Review URL: https://chromiumcodereview.appspot.com/11308129

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@169446 0039d316-1c4b-4281-b951-d872f2087c98
12 years ago
ilevy@chromium.org 216492603a Improve error message when gclient can't update
R=maruel@chromium.org


Review URL: https://chromiumcodereview.appspot.com/11360150

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@166846 0039d316-1c4b-4281-b951-d872f2087c98
12 years ago
maruel@chromium.org 6fd50f51e4 Fix update_depot_tools for git checkout
Otherwise, the output was:
  fatal: Needed a single revision
  invalid upstream origin

R=szager@chromium.org
BUG=
TEST=


Review URL: https://chromiumcodereview.appspot.com/10784045

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@147064 0039d316-1c4b-4281-b951-d872f2087c98
13 years ago
cmp@chromium.org b9d08cece4 Handle updating depot_tools repos that are git cloned.
Until recently, no proper Git clone of depot_tools existed.
All Git clones were set up locally via git svn clone.  The
way repos of that type are updated is via 'git svn rebase'.

Now, a supported Git clone of depot_tools exists.  The
update process for repos of this type is via 'git fetch'
and 'git rebase'.

Modify the update_depot_tools* scripts so they can update
depot_tools for git cloned or git svn cloned methods.  This
also means that git svn is no longer required, so move that
test after we check for git cloned repos.

R=maruel@chromium.org

TEST=Linux + git clone: on Linux, git clone
https://git.chromium.org/chromium/tools/depot_tools.git.  Apply
and commit this patch locally.  Note commit hash of HEAD.  Run
'git reset --hard "HEAD^^^"'.  Run
'git cherry-pick HASH_OF_UPDATE_CHANGE'.  Run './update_depot_tools'.
Verify depot_tools is updated to latest available revision + this
change.

TEST=Linux + git svn clone: on Linux, git svn clone
svn://svn.chromium.org/chrome/trunk/tools/depot_tools.
Apply and commit this patch locally.  Note commit hash
of HEAD.  Run 'git reset --hard "HEAD^^^"'.  Run 'git cherry-pick
HASH_OF_UPDATE_CHANGE'.  Run './update_depot_tools'.  Verify
depot_tools is updated to latest available revision + this change.

TEST=Windows command prompt + git clone: on Windows command prompt,
run Linux+git clone test, except use update_depot_tools.bat.  Verify
depot_tools is updated to latest available revision + this change.

TEST=Windows command prompt + git svn clone: on Windows command
prompt, run Linux+git svn clone test, except use
update_depot_tools.bat.  Verify depot_tools is updated to latest
available revision + this change.

TEST=Windows cygwin + git clone: on Windows command prompt,
run Linux+git clone test.  Verify depot_tools is updated to latest
available revision + this change.

TEST=Windows cygwin + git svn clone: on Windows command
prompt, run Linux+git svn clone test.  Verify depot_tools is updated
to latest available revision + this change.

Review URL: https://chromiumcodereview.appspot.com/10263004

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@134732 0039d316-1c4b-4281-b951-d872f2087c98
13 years ago
maruel@chromium.org e6c00f3f6f Fix git depot_tools update flow.
In Windows (already worked correctly in posix): gclient wouldn't correctly update depot_tools when called.

Refactored away the bootstrap depot_tools update flow which only still existed in Windows.

Patch contributed by gab@chromium.org

R=maruel@chromium.org
BUG=
TEST=Running `gclient sync` from src/ and see depot_tools being correctly updated under a git depot_tools checkout.

Review URL: https://chromiumcodereview.appspot.com/9751009

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@132191 0039d316-1c4b-4281-b951-d872f2087c98
13 years ago
dpranke@chromium.org bda0503b54 change -delete to -exec rm {} \;
TBR=maruel@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/8073008

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@103214 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 81a82a980a Delete all .pyc on update. Stale .pyc can cause weird issues.
Take two at r102841.

Forgot to use $base_dir, so the .pyc files in the checkout were deleted, instead
of the ones in depot_tools. Since some slaves have very large checkouts, they
appeared as hung.

R=cmp@chromium.org
BUG=
TEST=


Review URL: http://codereview.chromium.org/8059001

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@103056 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
thestig@chromium.org 809ab90e1f Revert r102841 - Delete all *.pyc on update. It's causing bots to time out in their update step.
TBR=maruel,asvitkine
Review URL: http://codereview.chromium.org/8052003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@102859 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 61fd2fad75 Delete all *.pyc on update
Last change exhibited issues with stale .pyc files. Let's leave that bake in a
little to cleanup old .pyc files.

TBR=asvitkine@chromium.org
BUG=
TEST=


Review URL: http://codereview.chromium.org/8048014

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@102841 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
cmp@chromium.org 4c6e404cf9 Make git-cl and update_depot_tools msys-compatible.
This change makes it possible to run 'git cl' from
a Command Prompt using only the auto-installed git
from depot_tools.  It is needed because in MSysGit,
'git cl' invokes 'git' which calls 'git-cl'.  While
'git-cl' is pulled from depot_tools (since it's in
PATH), depot_tools/python_bin is not in PATH, and
so we execute git_cl.py through our auto-installed
python.exe directly.

update_depot_tools is fixed so that if we find
the auto-installed svn and git in depot_tools, we
execute those directly, otherwise falling back to
calling them based on PATH.

In both git-cl and update_depot_tools, we only enable
this new behavior if uname in PATH reports a 'MINGW'
environment.  This should not trigger on any other
environment where uname exists, including Cygwin which
should report 'CYGWIN'.
Review URL: http://codereview.chromium.org/7020035

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@87510 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
nsylvain@chromium.org f9328b9b72 Revert 86501: Make git-cl and update_depot_tools msys-compatible.
Review URL: http://codereview.chromium.org/7008006

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@86552 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
cmp@chromium.org 6dbde57841 Make git-cl and update_depot_tools msys-compatible.
Review URL: http://codereview.chromium.org/7055025

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@86501 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
cmp@chromium.org 711a16a9cd Revert r86185 use /bin/bash for update_depot_tools.
This is causing a failure with dash interpreters.
Will revert this change and do testing in that
environment before next landing.

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@86211 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
cmp@chromium.org 86def49789 Use /bin/bash for update_depot_tools.
On at least one platform /usr/bin/env is actually not
a guaranteed method to get to bash.  Fall back to using
/bin/bash for this script.
Review URL: http://codereview.chromium.org/7039045

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@86185 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 31dcb497a0 Early exit auto-update when running as root.
Otherwise it can mess with file permissions.

R=dpranke@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7016002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@85178 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
mark@chromium.org 736aefea58 Only show "Depot Tools has been updated" messages when the tools are actually
updated; show the real last-change revision and not the current HEAD revision.

BUG=none
TEST=none
Review URL: http://codereview.chromium.org/6881049

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@82124 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 3bc36d136c Remove remaining cygwin check in wrapper scripts.
Looks like we had forgot gcl.

R=dpranke@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/6838028

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@81654 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
scottbyer@chromium.org 6fe66e1946 update_depot_tools: Workaound svn symlink issue.
svn info doesn't like it when handed a symlink - you get an 'is not a working copy' error message. Unfortunately, the Mac uses BSD readlink, and doesn't have -f, so the subshell CD/PWD idiom must be used.

BUG=none
TEST=Create a symlink to depot_tools, put it early in your path, and do update_depot_tools. You should not get any 'not a working copy' error messages.
Review URL: http://codereview.chromium.org/6838001

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@81323 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 529e97b799 Prints the depot_tools update notification to stderr instead of stdout.
Otherwise it's painful when using tricks like $(git cl upstream).

R=sky@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/6727012

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@79084 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 602e0a7e88 Fix a regression introduced in r77997.
An error message would be printed at each update_depot_tools invocation.

TBR=mhm
BUG=none
TEST=running gclient shouldn't print an error message at each invocation anymore

Review URL: http://codereview.chromium.org/6690008

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@78021 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
mhm@chromium.org 31ced09fa6 Add a message to the screen when depot tools have been updated.
BUG=none
TEST=message appears only when new revision changes.

Review URL: http://codereview.chromium.org/6691001

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@77997 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
mhm@chromium.org 7ace24df73 Support msysgit with Chromium.
First step to remove cygwin dependencies. This will remove dependencies with zcsh and allow python scripts to be executed as hooks.

BUG=70550, 70549
TEST=checkout chrome with git, use git cl to upload a cl, revise a cl, commit a cl.

Review URL: http://codereview.chromium.org/6369012

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@76232 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
bradnelson@google.com 28e0e9408d Changing entry points to use cygwin python (as gyp will now fall back on
hermetic python).


BUG=http://code.google.com/p/gyp/issues/detail?id=178
TEST=None

Review URL: http://codereview.chromium.org/6557004

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@75768 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
maruel@chromium.org 3bb0d6fa0b Change shebangs to allow the tools to be used out of the box without modification
on system that don't hard code bash's path.

For example, BSD's bash lives in /usr/local/bin on freebsd & openbsd.

Patch contributed by Sevan Janiyan (venture37 at gmail)

TEST=didn't break ubuntu users
BUG=none

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@66124 0039d316-1c4b-4281-b951-d872f2087c98
14 years ago
scottbyer@chromium.org 7526fe3b28 A refactoring left cygwin busted.
Create an update_depot_tools.bat file to use for updated when on cygwin, and
properly call it from the update_depot_tools shell script and gclient batch
files.

BUG=none
TEST=gclient sync and git cl work again on cygwin.  Can also turn echo on in update_depot_tools.bat to verify updating working correctly.

Review URL: http://codereview.chromium.org/3856006

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@63234 0039d316-1c4b-4281-b951-d872f2087c98
15 years ago
msb@chromium.org 2a94904744 Isolate depot_tools update into a separate script.
Also, modify git-cl to also update depot_tools. Otherwise, the git-cl
script never gets updated for folks that only use git-cl but
not gclient. This fixes a bug ChromiumOS developers are currently seeing
where there git-cl checkout is still pointing to src.chromium.org
and not git.chromium.org.

BUG=none
TEST=Verified that git-cl help and gclient help work.

Review URL: http://codereview.chromium.org/3817011

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