MCPcopy Index your code
hub / github.com/dashed/git-chain / first_commit_all

Function first_commit_all

tests/common/mod.rs:162–170  ·  view source on GitHub ↗
(repo: &Repository, message: &str)

Source from the content-addressed store, hash-verified

160}
161
162pub fn first_commit_all(repo: &Repository, message: &str) {
163 // HEAD should not resolve to anything prior to creating the first commit
164 assert!(repo.head().is_err());
165
166 // stage all changes - git add -A *
167 let root_tree_oid = stage_everything(repo);
168
169 create_first_commit(repo, root_tree_oid, message);
170}
171
172pub fn commit_all(repo: &Repository, message: &str) {
173 // stage all changes - git add -A *

Calls 2

stage_everythingFunction · 0.85
create_first_commitFunction · 0.85