gclient: print an error message instead of crashing

When 'gclient recurse' is called from a unconfigured directory.
No functional change otherwise.

R=agable@chromium.org
Bug:774749
Change-Id: Ifb2b74c042ce31faf3e1287c5614739e58e9178c
Reviewed-on: https://chromium-review.googlesource.com/726419
Reviewed-by: Aaron Gable <agable@chromium.org>
Commit-Queue: Marc-Antoine Ruel <maruel@chromium.org>
changes/19/726419/2
Marc-Antoine Ruel 8 years ago committed by Commit Bot
parent 590420d5d4
commit e6e0641b15

@ -1724,6 +1724,8 @@ def CMDrecurse(parser, args):
options.nohooks = True
client = GClient.LoadCurrentConfig(options)
if not client:
raise gclient_utils.Error('client not configured; see \'gclient config\'')
return client.RunOnDeps('recurse', args, ignore_requirements=True,
progress=not options.no_progress)

Loading…
Cancel
Save