MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / git

Function git

atomic-cli/tests/it/git_import_sibling_closure_regression.rs:57–76  ·  view source on GitHub ↗
(root: &Path, args: &[&str])

Source from the content-addressed store, hash-verified

55}
56
57fn git(root: &Path, args: &[&str]) -> String {
58 let output = Command::new("git")
59 .args(args)
60 .current_dir(root)
61 .env("GIT_AUTHOR_NAME", "Sibling Closure Tests")
62 .env("GIT_AUTHOR_EMAIL", "sibling-closure@example.com")
63 .env("GIT_COMMITTER_NAME", "Sibling Closure Tests")
64 .env("GIT_COMMITTER_EMAIL", "sibling-closure@example.com")
65 .output()
66 .expect("run git");
67 assert!(
68 output.status.success(),
69 "git {args:?} failed: {}",
70 String::from_utf8_lossy(&output.stderr)
71 );
72 String::from_utf8(output.stdout)
73 .expect("utf8 git output")
74 .trim()
75 .to_string()
76}
77
78/// Commit with a controlled committer date (the deterministic shim
79/// sequencing's first tie-break), so the sibling lands between the parent

Callers 2

commit_atFunction · 0.70
sibling_fixtureFunction · 0.70

Calls 1

outputMethod · 0.45

Tested by

no test coverage detected