MCPcopy Create free account
hub / github.com/IntegralPilot/rustc_codegen_jvm / is_stale

Function is_stale

build.py:82–94  ·  view source on GitHub ↗

Checks if the target file is older than any source file.

(target: Path, sources: List[Path])

Source from the content-addressed store, hash-verified

80 cwd_str = f" (in {cwd})" if cwd else ""
81 print(f"{Colors.YELLOW}▶️ Running: {' '.join(cmd)}{cwd_str}{Colors.RESET}")
82 try:
83 proc = subprocess.run(
84 cmd,
85 cwd=cwd,
86 check=check,
87 stdout=sys.stdout, # Stream output directly
88 stderr=sys.stderr
89 )
90 return proc
91 except FileNotFoundError as e:
92 print(f"{Colors.RED}❌ Error: Command '{cmd[0]}' not found. Is it in your PATH?{Colors.RESET}")
93 print(f" Details: {e}")
94 sys.exit(1)
95 except subprocess.CalledProcessError as e:
96 print(f"{Colors.RED}❌ Command failed with exit code {e.returncode}.{Colors.RESET}")
97 sys.exit(e.returncode)

Callers 4

build_libraryFunction · 0.85
generate_shim_metadataFunction · 0.85
build_rust_backendFunction · 0.85
build_java_linkerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected