Chromium Code Reviews| Index: gclient.py |
| =================================================================== |
| --- gclient.py (revision 123383) |
| +++ gclient.py (working copy) |
| @@ -1166,6 +1166,22 @@ |
| return 0 |
| +def CMDfetch(parser, args): |
| + """Fetches upstream commits for all modules. |
| + |
| +Completely git-specific. Simply runs 'git fetch origin' for each module. |
| +""" |
| + parser.remove_option('--jobs') |
|
M-A Ruel
2012/02/27 16:52:48
It's useful and safe to do them in parallel. I'd k
|
| + (options, parsed_args) = parser.parse_args(args) |
|
M-A Ruel
2012/02/27 16:52:48
Why parse the arguments here? Just forward the mod
|
| + if parsed_args: |
| + print >> sys.stderr, 'Fetch accepts no arguments!' |
| + return 1 |
| + args.extend('-s git git fetch origin'.split(' ')) |
|
M-A Ruel
2012/02/27 16:52:48
Let's do
args = ['-s', 'git', 'git', 'fetch'] + ar
|
| + # Add jobs option back, so CMDrecurse doesn't freak. |
| + parser.add_option('--jobs') |
| + return CMDrecurse(parser, args) |
| + |
| + |
| @attr('usage', '[url] [safesync url]') |
| def CMDconfig(parser, args): |
| """Create a .gclient file in the current directory. |