1
0
mirror of https://github.com/facebook/proxygen.git synced 2025-08-08 18:02:05 +03:00

fbcode_builder: getdeps: add build options

Summary:
The build options class contains some environmental and
build related information that will be passed down to fetcher
and builder objects that will be introduced in later diffs.

Reviewed By: simpkins

Differential Revision: D14691007

fbshipit-source-id: e8fe7322f590667ac28a5a3925a072056df0b3e3
This commit is contained in:
Wez Furlong
2019-05-03 15:52:39 -07:00
committed by Facebook Github Bot
parent bd620998c4
commit bf022a1adf
3 changed files with 254 additions and 4 deletions

View File

@@ -25,11 +25,13 @@ class SubCmd(object):
CmdTable = []
def add_subcommands(parser, cmd_table=CmdTable):
def add_subcommands(parser, common_args, cmd_table=CmdTable):
""" Register parsers for the defined commands with the provided parser """
for cls in cmd_table:
command = cls()
command_parser = parser.add_parser(command.NAME, help=command.HELP)
command_parser = parser.add_parser(
command.NAME, help=command.HELP, parents=[common_args]
)
command.setup_parser(command_parser)
command_parser.set_defaults(func=command.run)