blob: 22c9295eba8b3bb52d9612f35fcf950918e4222c [file] [log] [blame]
maruel@chromium.org3bb0d6f2010-11-15 17:01:52 +00001#!/usr/bin/env bash
maruel@google.comfb2b8eb2009-04-23 21:03:42 +00002# Copyright (c) 2009 The Chromium Authors. All rights reserved.
3# Use of this source code is governed by a BSD-style license that can be
4# found in the LICENSE file.
5
maruel@google.comfb2b8eb2009-04-23 21:03:42 +00006base_dir=$(dirname "$0")
maruel@chromium.org522ca092009-06-17 18:35:18 +00007
Edward Lemur3c814952019-08-12 19:43:00 +00008# Update depot_tools unless DEPOT_TOOLS_UPDATE is set to 0
9if [ "X$DEPOT_TOOLS_UPDATE" != "X0" ]; then
10 if [[ "#grep#fetch#cleanup#diff#setdep#" != *"#$1#"* ]]; then
11 "$base_dir"/update_depot_tools "$@"
12 case $? in
13 123)
14 # msys environment was upgraded, need to quit.
15 exit 0
16 ;;
17 0)
18 ;;
19 *)
20 exit $?
21 esac
22 fi
ilevy@chromium.org3addce32012-11-08 23:02:13 +000023fi
maruel@chromium.org522ca092009-06-17 18:35:18 +000024
Edward Lemur3c814952019-08-12 19:43:00 +000025PYTHONDONTWRITEBYTECODE=1 exec $base_dir/vpython "$base_dir/gclient.py" "$@"