MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / _cargo_command

Function _cargo_command

misc/python/materialize/cli/run.py:500–518  ·  view source on GitHub ↗
(args: argparse.Namespace, *subcommands: str)

Source from the content-addressed store, hash-verified

498
499
500def _cargo_command(args: argparse.Namespace, *subcommands: str) -> list[str]:
501 command = ["cargo"]
502 if args.channel:
503 command += [args.channel]
504 command += subcommands
505 if args.release:
506 command += ["--release"]
507 if args.optimized:
508 command += [
509 "--cargo-profile" if subcommands == ("nextest", "run") else "--profile",
510 "optimized",
511 ]
512 if args.timings:
513 command += ["--timings"]
514 if args.no_default_features:
515 command += ["--no-default-features"]
516 if args.sanitizer != "none":
517 command += ["-Zbuild-std", "--target", SANITIZER_TARGET]
518 return command
519
520
521def _cargo_artifact_path(args: argparse.Namespace, program: str) -> pathlib.Path:

Callers 2

mainFunction · 0.85
_cargo_buildFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected