File tree 1 file changed +6
-4
lines changed
crates/gitbutler-repo/src 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -450,13 +450,13 @@ impl RepositoryExt for git2::Repository {
450
450
}
451
451
452
452
let args = format ! (
453
- "{} -U {} " ,
453
+ "'{}' -U '{}' " ,
454
454
key_storage. path( ) . to_string_lossy( ) ,
455
455
buffer_file_to_sign_path_str,
456
456
) ;
457
457
cmd_string += & args;
458
458
} else {
459
- let args = format ! ( "{} {} " , signing_key, buffer_file_to_sign_path_str) ;
459
+ let args = format ! ( "'{}' '{}' " , signing_key, buffer_file_to_sign_path_str) ;
460
460
cmd_string += & args;
461
461
} ;
462
462
let mut signing_cmd: std:: process:: Command = command_with_login_shell ( cmd_string) ;
@@ -581,11 +581,13 @@ impl RepositoryExt for git2::Repository {
581
581
}
582
582
583
583
pub fn command_with_login_shell ( shell_cmd : impl Into < OsString > ) -> std:: process:: Command {
584
- gix:: command:: prepare ( shell_cmd)
584
+ let cmd : std :: process :: Command = gix:: command:: prepare ( shell_cmd)
585
585
. with_shell_disallow_manual_argument_splitting ( )
586
586
// On Windows, this yields the Git-bundled `sh.exe`, on Linux it uses `/bin/sh`.
587
587
. with_shell_program ( gix:: path:: env:: shell ( ) )
588
- . into ( )
588
+ . into ( ) ;
589
+ tracing:: debug!( ?cmd, "command to produce commit signature" ) ;
590
+ cmd
589
591
}
590
592
591
593
/// Signs the buffer with the configured gpg key, returning the signature.
You can’t perform that action at this time.
0 commit comments