Exemplo n.º 1
0
def rule_runner() -> RuleRunner:
    rule_runner = RuleRunner(
        rules=[
            *config_files.rules(),
            *coursier_fetch_rules(),
            *coursier_setup_rules(),
            *dep_inference_rules(),
            *external_tool_rules(),
            *scala_parser.rules(),
            *symbol_mapper.rules(),
            *scala_target_rules(),
            *source_files.rules(),
            *util_rules(),
            *jdk_rules(),
            QueryRule(Addresses, [DependenciesRequest]),
            QueryRule(ExplicitlyProvidedDependencies, [DependenciesRequest]),
            QueryRule(InferredDependencies, [InferScalaSourceDependencies]),
            QueryRule(Targets, [UnparsedAddressInputs]),
        ],
        target_types=[ScalaSourcesGeneratorTarget],
    )
    rule_runner.set_options(
        args=[NAMED_RESOLVE_OPTIONS, DEFAULT_RESOLVE_OPTION], env_inherit=PYTHON_BOOTSTRAP_ENV
    )
    return rule_runner
Exemplo n.º 2
0
def rule_runner() -> RuleRunner:
    rule_runner = RuleRunner(
        rules=[
            *config_files.rules(),
            *jvm_tool.rules(),
            *java_dep_inference_rules(),
            *java_target_rules(),
            *java_util_rules(),
            *javac_rules(),
            *java_symbol_mapper.rules(),
            *source_files.rules(),
            *scala_parser.rules(),
            *scala_symbol_mapper.rules(),
            *scala_dep_inference_rules.rules(),
            *scala_target_types.rules(),
            *system_binaries.rules(),
            *util_rules(),
            QueryRule(Addresses, (DependenciesRequest, )),
        ],
        target_types=[
            JavaSourcesGeneratorTarget,
            JavaSourceTarget,
            ScalaSourcesGeneratorTarget,
            ScalaSourceTarget,
        ],
    )
    rule_runner.set_options(args=[], env_inherit=PYTHON_BOOTSTRAP_ENV)
    return rule_runner
Exemplo n.º 3
0
def rules():
    return [
        *collect_rules(),
        *artifact_mapper.rules(),
        *scala_parser.rules(),
        *symbol_mapper.rules(),
        UnionRule(InferDependenciesRequest, InferScalaSourceDependencies),
    ]
Exemplo n.º 4
0
def rules():
    return [
        *collect_rules(),
        *artifact_mapper.rules(),
        *scala_parser.rules(),
        *scalac_plugins.rules(),
        *symbol_mapper.rules(),
        UnionRule(InferDependenciesRequest, InferScalaSourceDependencies),
        UnionRule(InjectDependenciesRequest, InjectScalaLibraryDependencyRequest),
        UnionRule(InjectDependenciesRequest, InjectScalaPluginDependenciesRequest),
    ]
Exemplo n.º 5
0
def rule_runner() -> RuleRunner:
    rule_runner = RuleRunner(
        rules=[
            *scala_parser.rules(),
            *jvm_tool.rules(),
            *source_files.rules(),
            *jdk_rules.rules(),
            *target_types.rules(),
            *jvm_util_rules.rules(),
            QueryRule(SourceFiles, (SourceFilesRequest,)),
            QueryRule(ScalaSourceDependencyAnalysis, (SourceFiles,)),
        ],
        target_types=[ScalaSourceTarget],
    )
    rule_runner.set_options(args=["-ldebug"], env_inherit=PYTHON_BOOTSTRAP_ENV)
    return rule_runner
Exemplo n.º 6
0
def rule_runner() -> RuleRunner:
    rule_runner = RuleRunner(
        preserve_tmpdirs=True,
        rules=[
            *scala_parser.rules(),
            *coursier_fetch_rules(),
            *coursier_setup_rules(),
            *external_tool_rules(),
            *source_files.rules(),
            *jdk_rules.rules(),
            *target_types.rules(),
            *jvm_util_rules.rules(),
            QueryRule(SourceFiles, (SourceFilesRequest,)),
            QueryRule(ScalaSourceDependencyAnalysis, (SourceFiles,)),
        ],
        target_types=[JvmDependencyLockfile, ScalaSourceTarget],
    )
    rule_runner.set_options(args=["-ldebug"], env_inherit=PYTHON_BOOTSTRAP_ENV)
    return rule_runner
Exemplo n.º 7
0
def rule_runner() -> RuleRunner:
    rule_runner = RuleRunner(
        rules=[
            *config_files.rules(),
            *jvm_tool.rules(),
            *dep_inference_rules(),
            *scala_parser.rules(),
            *symbol_mapper.rules(),
            *scala_target_rules(),
            *source_files.rules(),
            *util_rules(),
            *jdk_rules(),
            QueryRule(Addresses, [DependenciesRequest]),
            QueryRule(ExplicitlyProvidedDependencies, [DependenciesRequest]),
            QueryRule(InferredDependencies, [InferScalaSourceDependencies]),
            QueryRule(Targets, [UnparsedAddressInputs]),
        ],
        target_types=[ScalaSourcesGeneratorTarget],
        objects={"parametrize": Parametrize},
    )
    rule_runner.set_options(args=[], env_inherit=PYTHON_BOOTSTRAP_ENV)
    return rule_runner