Skip to content

Commit

Permalink
adapt to changes in gix-command
Browse files Browse the repository at this point in the history
  • Loading branch information
Byron committed Jan 23, 2025
1 parent 667de43 commit 28f712e
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions gix-credentials/src/program/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,14 @@ impl Program {
args.insert_str(0, git_program.to_string_lossy().as_ref());
gix_command::prepare(gix_path::from_bstr(args.as_bstr()).into_owned())
.arg(action.as_arg(true))
.with_shell_allow_manual_argument_splitting()
.command_may_be_shell_script_allow_manual_argument_splitting()
.into()
}
Kind::ExternalShellScript(for_shell)
| Kind::ExternalPath {
path_and_args: for_shell,
} => gix_command::prepare(gix_path::from_bstr(for_shell.as_bstr()).as_ref())
.with_shell()
.command_may_be_shell_script()
.arg(action.as_arg(true))
.into(),
};
Expand Down
2 changes: 1 addition & 1 deletion gix-diff/src/blob/pipeline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,7 @@ impl Driver {
let cmd = gix_command::prepare(gix_path::from_bstr(command).into_owned())
// TODO: Add support for an actual Context, validate it *can* match Git
.with_context(Default::default())
.with_shell()
.command_may_be_shell_script()
.stdin(Stdio::null())
.stdout(Stdio::piped())
.stderr(Stdio::piped())
Expand Down
2 changes: 1 addition & 1 deletion gix-filter/src/driver/init.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ fn spawn_driver(
context: &gix_command::Context,
) -> Result<(std::process::Child, std::process::Command), Error> {
let mut cmd: std::process::Command = gix_command::prepare(gix_path::from_bstr(cmd).into_owned())
.with_shell()
.command_may_be_shell_script()
.with_context(context.clone())
.stdin(Stdio::piped())
.stdout(Stdio::piped())
Expand Down
2 changes: 1 addition & 1 deletion gix-merge/src/blob/platform/merge.rs
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ pub(super) mod inner {
Ok(merge::Command {
cmd: gix_command::prepare(gix_path::from_bstring(cmd))
.with_context(context)
.with_shell()
.command_may_be_shell_script()
.stdin(Stdio::null())
.stdout(Stdio::inherit())
.stderr(Stdio::inherit())
Expand Down
2 changes: 1 addition & 1 deletion gix-transport/src/client/blocking_io/ssh/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ pub fn connect(
.stderr(Stdio::null())
.stdout(Stdio::null())
.stdin(Stdio::null())
.with_shell()
.command_may_be_shell_script()
.arg("-G")
.arg(match url.host_as_argument() {
Usable(host) => host,
Expand Down
2 changes: 1 addition & 1 deletion gix-transport/src/client/blocking_io/ssh/program_kind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ impl ProgramKind {
desired_version: Protocol,
disallow_shell: bool,
) -> Result<gix_command::Prepare, ssh::invocation::Error> {
let mut prepare = gix_command::prepare(ssh_cmd).with_shell();
let mut prepare = gix_command::prepare(ssh_cmd).command_may_be_shell_script();
if disallow_shell {
prepare.use_shell = false;
}
Expand Down

0 comments on commit 28f712e

Please sign in to comment.