Commit Graph

7 Commits (40764b07d0583624a4f22edb40ecb928f7f9ef0d)

Author SHA1 Message Date
Dan Jacques 3d9b58819b [win_tools] Use bundled Python CIPD packages (#2).
Re-land of bf1446791e.

Enable bundled Python CIPD packages in bleeding-edge mode. This
replaces the ZIP unpacking approach used before, and introduces
validation and management through the CIPD tool. The bleeding edge
version will only install if a sentinel file is present in the
"depot_tools" root; otherwise, default behavior will continue.

This method adds a upgrade and downgrade path to/from ZIP and
CIPD installations. This is done by rewriting the "win_tools.bat"
process:

1) Ensure that a bootstrap Python is present.
2) Use it to run "win_tools.py", which has the functionality of
    "git_bootstrap.py" plus Python installation.
3) Run "win_tools.py" with appropriate flags.

Some tricks were employed to handle cases where there is an
already-running Python instance that uses the current Python
installation and executable. This happens on bots because the
system uses the same "depot_tools" checkout at multiple launch
layers. To this end, we use the "python.bat" as the "current Python"
authority and refrain from cleaning up old Python directories if their
"python.exe" binaries are currently in use.

We change the Git bleeding edge file to share the same
sentinel file as Python, ".bleeding_edge".

The new Python should have the same facilities as the original Python
bundle.

BUG=chromium:740171
TEST=local

Change-Id: I51ba6415c60b95c2aaba94b6e21bd9b3fc82f35d
Reviewed-on: https://chromium-review.googlesource.com/568524
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Robbie Iannucci <iannucci@chromium.org>
8 years ago
Andrii Shyshkalov af5c20f5a4 Revert "[win_tools] Use bundled Python CIPD packages."
This reverts commit bf1446791e.

Reason for revert: broke win bots http://o/410053

Original change's description:
> [win_tools] Use bundled Python CIPD packages.
> 
> Enable bundled Python CIPD packages in bleeding-edge mode. This
> replaces the ZIP unpacking approach used before, and introduces
> validation and management through the CIPD tool. The bleeding edge
> version will only install if a sentinel file is present in the
> "depot_tools" root; otherwise, default behavior will continue.
> 
> This method adds a upgrade and downgrade path to/from ZIP and
> CIPD installations. This is done by rewriting the "win_tools.bat"
> process:
> 
> 1) Ensure that a bootstrap Python is present.
> 2) Use it to run "win_tools.py", which has the functionality of
>     "git_bootstrap.py" plus Python installation.
> 3) Run "win_tools.py" with appropriate flags.
> 
> Some tricks were employed to handle cases where there is an
> already-running Python instance that uses the current Python
> installation and executable. This happens on bots because the
> system uses the same "depot_tools" checkout at multiple launch
> layers. To this end, we use the "python.bat" as the "current Python"
> authority and refrain from cleaning up old Python directories if their
> "python.exe" binaries are currently in use.
> 
> We change the Git bleeding edge file to share the same
> sentinel file as Python, ".bleeding_edge".
> 
> The new Python should have the same facilities as the original Python
> bundle.
> 
> BUG=chromium:740171
> TEST=local
> 
> Change-Id: I1b3b7d31d47d1a37a9dba9114d31681bec558736
> Reviewed-on: https://chromium-review.googlesource.com/563036
> Commit-Queue: Daniel Jacques <dnj@chromium.org>
> Reviewed-by: Robbie Iannucci <iannucci@chromium.org>

TBR=iannucci@chromium.org,dnj@chromium.org

Change-Id: I84574a01bbad6596912e4aaa34f019d24720b638
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:740171
Reviewed-on: https://chromium-review.googlesource.com/567009
Reviewed-by: Andrii Shyshkalov <tandrii@chromium.org>
Commit-Queue: Andrii Shyshkalov <tandrii@chromium.org>
8 years ago
Dan Jacques bf1446791e [win_tools] Use bundled Python CIPD packages.
Enable bundled Python CIPD packages in bleeding-edge mode. This
replaces the ZIP unpacking approach used before, and introduces
validation and management through the CIPD tool. The bleeding edge
version will only install if a sentinel file is present in the
"depot_tools" root; otherwise, default behavior will continue.

This method adds a upgrade and downgrade path to/from ZIP and
CIPD installations. This is done by rewriting the "win_tools.bat"
process:

1) Ensure that a bootstrap Python is present.
2) Use it to run "win_tools.py", which has the functionality of
    "git_bootstrap.py" plus Python installation.
3) Run "win_tools.py" with appropriate flags.

Some tricks were employed to handle cases where there is an
already-running Python instance that uses the current Python
installation and executable. This happens on bots because the
system uses the same "depot_tools" checkout at multiple launch
layers. To this end, we use the "python.bat" as the "current Python"
authority and refrain from cleaning up old Python directories if their
"python.exe" binaries are currently in use.

We change the Git bleeding edge file to share the same
sentinel file as Python, ".bleeding_edge".

The new Python should have the same facilities as the original Python
bundle.

BUG=chromium:740171
TEST=local

Change-Id: I1b3b7d31d47d1a37a9dba9114d31681bec558736
Reviewed-on: https://chromium-review.googlesource.com/563036
Commit-Queue: Daniel Jacques <dnj@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
8 years ago
iannucci@chromium.org 51bcc4301e Fix bash math for `git bash` alias.
Previous calculation was off-by-one.

TBR=dnj@chromium.org, mmoss@chromium.org
BUG=598956

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299619 0039d316-1c4b-4281-b951-d872f2087c98
9 years ago
iannucci@chromium.org 0703ea2cc6 Multiple improvements to windows bash integration.
* `git bash` helper now will either:
    * launch an interactive bash prompt in the MinGW Terminal Emulator
    * launch a non-interactive bash shell if arguments are provided
  * `git bash` now includes python, python/Scripts and svn binaries in
    the PATH.
  * depot_tools' colorization now works in MinGW Terminal Emulator
  * batch scripts are now regenerated if any of them is missing.

R=agable@chromium.org, dnj@chromium.org, mmoss@chromium.org
BUG=598956

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299616 0039d316-1c4b-4281-b951-d872f2087c98
9 years ago
iannucci@chromium.org c0f8642119 Revert "Better tooling"
This reverts commit eed06d620f.

Accidental dcommit

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299615 0039d316-1c4b-4281-b951-d872f2087c98
9 years ago
iannucci@chromium.org eed06d620f Better tooling
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299614 0039d316-1c4b-4281-b951-d872f2087c98
9 years ago