Redo the python check to look for the directories too.

This way, DEPOT_TOOLS_PYTHON_275=1 will properly upgrade an installation
still running 2.6. Otherwise the user had to "del python.bat" to force
the upgrade.

Stop calling python to verify it works, this is slow.

Upgrade url to https.

R=iannucci@chromium.org
BUG=241769

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@228179 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/bootstrap/win/win_tools.bat b/bootstrap/win/win_tools.bat
index 9fa3d2d..2f7d044 100644
--- a/bootstrap/win/win_tools.bat
+++ b/bootstrap/win/win_tools.bat
@@ -9,7 +9,7 @@
 :: Sadly, we can't use SETLOCAL here otherwise it ERRORLEVEL is not correctly

 :: returned.

 

-set WIN_TOOLS_ROOT_URL=http://src.chromium.org/svn/trunk/tools

+set WIN_TOOLS_ROOT_URL=https://src.chromium.org/svn/trunk/tools

 set GIT_BIN_DIR=git-1.8.0_bin

 

 :: Get absolute root directory (.js scripts don't handle relative paths well).

@@ -113,21 +113,22 @@
 

 

 :PYTHON_CHECK

-:: If the batch file exists, skip the python check.

-set ERRORLEVEL=0

-if exist "%WIN_TOOLS_ROOT_DIR%\python.bat" goto :END

-if "%WIN_TOOLS_FORCE%" == "1" goto :PYTHON_INSTALL

-call python --version 2>nul 1>nul

-if errorlevel 1 goto :PYTHON_INSTALL

+if "%DEPOT_TOOLS_PYTHON_275%" == "1" goto :PY275_CHECK

+goto :PY26_CHECK

 

-:: We are done.

+

+:PY26_CHECK

+if not exist "%WIN_TOOLS_ROOT_DIR%\python_bin" goto :PY26_INSTALL

+if not exist "%WIN_TOOLS_ROOT_DIR%\python.bat" goto :PY26_INSTALL

 set ERRORLEVEL=0

 goto :END

 

 

-:PYTHON_INSTALL

-if "%DEPOT_TOOLS_PYTHON_275%" == "1" goto :PY275_INSTALL

-goto :PY26_INSTALL

+:PY275_CHECK

+if not exist "%WIN_TOOLS_ROOT_DIR%\python275_bin" goto :PY275_INSTALL

+if not exist "%WIN_TOOLS_ROOT_DIR%\python.bat" goto :PY275_INSTALL

+set ERRORLEVEL=0

+goto :END

 

 

 :PY275_INSTALL