mirror of
https://github.com/facebook/proxygen.git
synced 2025-08-07 07:02:53 +03:00
fbcode_builder: getdeps: add GitFetcher
Summary: this fetcher knows how to check out sources via git. Reviewed By: simpkins Differential Revision: D14691000 fbshipit-source-id: 60f1ffbfed7b32a019aef6aa70ae0903f2782451
This commit is contained in:
committed by
Facebook Github Bot
parent
29b6a87eb8
commit
c4da97262f
@@ -11,6 +11,7 @@ from __future__ import absolute_import, division, print_function, unicode_litera
|
||||
import io
|
||||
|
||||
from .expr import parse_expr
|
||||
from .fetcher import GitFetcher
|
||||
|
||||
|
||||
try:
|
||||
@@ -257,6 +258,11 @@ class ManifestParser(object):
|
||||
return d
|
||||
|
||||
def create_fetcher(self, build_options, ctx):
|
||||
repo_url = self.get("git", "repo_url", ctx=ctx)
|
||||
if repo_url:
|
||||
rev = self.get("git", "rev")
|
||||
return GitFetcher(build_options, self, repo_url, rev)
|
||||
|
||||
raise KeyError(
|
||||
"project %s has no fetcher configuration matching %r" % (self.name, ctx)
|
||||
)
|
||||
|
Reference in New Issue
Block a user