Fix parsing of author name in git show output (#29704)
Closes #ISSUE Release Notes: - Fixed a bug causing incorrect formatting of git commit tooltips
This commit is contained in:
parent
fc920bf63d
commit
38ede4bae3
1 changed files with 2 additions and 2 deletions
|
@ -411,13 +411,13 @@ impl GitRepository for RealGitRepository {
|
|||
"--no-optional-locks",
|
||||
"show",
|
||||
"--no-patch",
|
||||
"--format=%H%x00%B%x00%at%x00%ae%x00%an",
|
||||
"--format=%H%x00%B%x00%at%x00%ae%x00%an%x00",
|
||||
&commit,
|
||||
])
|
||||
.output()?;
|
||||
let output = std::str::from_utf8(&output.stdout)?;
|
||||
let fields = output.split('\0').collect::<Vec<_>>();
|
||||
if fields.len() != 5 {
|
||||
if fields.len() != 6 {
|
||||
bail!("unexpected git-show output for {commit:?}: {output:?}")
|
||||
}
|
||||
let sha = fields[0].to_string().into();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue