Write index after committing
This commit is contained in:
parent
bee4c2002d
commit
0dc2baaee2
1 changed files with 7 additions and 1 deletions
|
@ -170,11 +170,17 @@ impl StoreIdAccessor for UpdateHook {
|
|||
let message = try!(commit_message(cfg, StoreAction::Update)
|
||||
.map_dbg_err_str("Failed to get commit message"));
|
||||
|
||||
repo.commit(Some("HEAD"), &signature, &signature, &message, &tree, &parents)
|
||||
try!(repo.commit(Some("HEAD"), &signature, &signature, &message, &tree, &parents)
|
||||
.map_dbg_str("Committed")
|
||||
.map_dbg_err_str("Failed to commit")
|
||||
.map_err_into(GHEK::RepositoryCommittingError)
|
||||
.map_into_hook_error()
|
||||
);
|
||||
|
||||
index.write()
|
||||
.map_err_into(GHEK::RepositoryIndexWritingError)
|
||||
.map_dbg_err_str("Failed to write tree")
|
||||
.map_into_hook_error()
|
||||
.map(|_| ())
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue