mirror of
https://github.com/gitui-org/gitui
synced 2026-05-23 17:08:21 +00:00
try setting email
This commit is contained in:
parent
018e87c20a
commit
4498a9b15b
1 changed files with 17 additions and 6 deletions
|
|
@ -83,12 +83,18 @@ pub fn commit(repo_path: &str, msg: &str) -> Result<CommitId> {
|
|||
#[cfg(test)]
|
||||
mod tests {
|
||||
|
||||
use crate::error::Result;
|
||||
use crate::sync::{
|
||||
commit, get_commit_details, get_commit_files, stage_add_file,
|
||||
tests::{get_statuses, repo_init, repo_init_empty},
|
||||
utils::get_head,
|
||||
LogWalker,
|
||||
use crate::{
|
||||
error::Result,
|
||||
sync::{
|
||||
commit, get_commit_details, get_commit_files,
|
||||
stage_add_file,
|
||||
tests::{
|
||||
debug_cmd_print, get_statuses, repo_init,
|
||||
repo_init_empty,
|
||||
},
|
||||
utils::get_head,
|
||||
LogWalker,
|
||||
},
|
||||
};
|
||||
use commit::amend;
|
||||
use git2::Repository;
|
||||
|
|
@ -202,6 +208,11 @@ mod tests {
|
|||
|
||||
stage_add_file(repo_path, file_path).unwrap();
|
||||
|
||||
debug_cmd_print(
|
||||
repo_path,
|
||||
"git config user.email 'foo@bar.com'",
|
||||
);
|
||||
|
||||
let id = commit(repo_path, "commit msg").unwrap();
|
||||
|
||||
let details = get_commit_details(repo_path, id).unwrap();
|
||||
|
|
|
|||
Loading…
Reference in a new issue