1
0
Fork 0
mirror of https://github.com/vbatts/git-validation.git synced 2024-11-26 10:05:40 +00:00

Replace CRLF in all commit messages which currently causes DCO check to fail

This commit is contained in:
Swagat Bora 2022-05-03 22:25:59 +00:00
parent 55b1840f58
commit ca901924b2

View file

@ -153,7 +153,8 @@ func LogCommit(commit string) (*CommitEntry, error) {
logrus.Errorf("[git] cmd: %q", strings.Join(cmd.Args, " ")) logrus.Errorf("[git] cmd: %q", strings.Join(cmd.Args, " "))
return nil, err return nil, err
} }
c[v] = strings.TrimSpace(string(out)) commitMessage := strings.ReplaceAll(string(out), "\r\n", "\n")
c[v] = strings.TrimSpace(commitMessage)
} }
return &c, nil return &c, nil