Permalink
Browse files

forall: Silently skip missing projects

If a project is missing locally, it might be OK to skip over it
and continue running the same command in other projects.

Bug: REPO-43
Change-Id: I64f97eb315f379ab2c51fc53d24ed340b3d09250
Signed-off-by: Shawn O. Pearce <sop@google.com>
(cherry picked from commit d4cd69b)
  • Loading branch information...
1 parent de8b2c4 commit 1b5a4a0c5de5fdaa4f8907357a0aa80e365dd199 @spearce spearce committed Aug 23, 2009
Showing with 6 additions and 0 deletions.
  1. +6 −0 subcmds/forall.py
View
@@ -169,6 +169,12 @@ def setenv(name, val):
else:
cwd = project.worktree
+ if not os.path.exists(cwd):
+ if (opt.project_header and opt.verbose) \
+ or not opt.project_header:
+ print >>sys.stderr, 'skipping %s/' % project.relpath
+ continue
+
if opt.project_header:
stdin = subprocess.PIPE
stdout = subprocess.PIPE

0 comments on commit 1b5a4a0

Please sign in to comment.