Skip to content

Commit

Permalink
PR Clone fix
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitcoder committed Nov 22, 2024
1 parent c294644 commit ea77bd9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ fn save_pr_branch_files(
}

// Set global Git config for user email and name
fn set_git_global_user_config() -> Result<(), Box<dyn std::error::Error>> {
pub fn set_git_global_user_config() -> Result<(), Box<dyn std::error::Error>> {
// Set global email
Command::new("git")
.args(&["config", "--global", "user.email", "[email protected]"])
Expand All @@ -439,7 +439,7 @@ pub fn checkout(
pr_branch: Option<&str>,
) -> Result<(), Box<dyn std::error::Error>> {
// Step 1: Clone the repository
set_git_user_config()?;
set_git_global_user_config()?;
let mut clone_cmd = Command::new("git");
clone_cmd.arg("clone").arg(clone_url).arg(clone_path);
if let Some(branch) = base_branch {
Expand Down

0 comments on commit ea77bd9

Please sign in to comment.