error if roll-dep command is called in Cog environment

Bug: 345486495
Change-Id: Ib48a1e8cbe51eccdd0a56e3105ce2f7b8d0c3dd1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5608832
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
changes/32/5608832/2
Yiwei Zhang 11 months ago committed by LUCI CQ
parent 4a8524d1e9
commit 954a8d7713

@ -16,6 +16,8 @@ import subprocess2
import sys
import tempfile
import gclient_utils
NEED_SHELL = sys.platform.startswith('win')
GCLIENT_PATH = os.path.join(os.path.dirname(os.path.abspath(__file__)),
'gclient.py')
@ -247,6 +249,10 @@ def finalize(commit_msg, current_dir, rolls):
def main():
if gclient_utils.IsEnvCog():
print('"roll-dep" is not supported in non-git environment',
file=sys.stderr)
return 1
parser = argparse.ArgumentParser(description=__doc__)
parser.add_argument('--ignore-dirty-tree',
action='store_true',

Loading…
Cancel
Save