Skip to content

Commit

Permalink
Try to fix #5839 by disallowing manual argument splitting. (#5839)
Browse files Browse the repository at this point in the history
That way, the shell will be used on Windows as well.
  • Loading branch information
Byron committed Jan 2, 2025
1 parent 018c038 commit f4115c3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions crates/gitbutler-repo/src/repository_ext.rs
Original file line number Diff line number Diff line change
Expand Up @@ -333,8 +333,9 @@ impl RepositoryExt for git2::Repository {
let args = format!("{} {}", signing_key, buffer_file_to_sign_path_str);
cmd_string += &args;
};
let mut signing_cmd: std::process::Command =
gix::command::prepare(cmd_string).with_shell().into();
let mut signing_cmd: std::process::Command = gix::command::prepare(cmd_string)
.with_shell_disallow_manual_argument_splitting()
.into();
let output = signing_cmd
.stderr(Stdio::piped())
.stdout(Stdio::piped())
Expand Down

0 comments on commit f4115c3

Please sign in to comment.