Skip to content

Commit f741e45

Browse files
committed
feat: throw exception if read commit message failed
1 parent 5ae7850 commit f741e45

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/src/read.dart

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ Future<Iterable<String>> _getRangeCommits({
3131
['log', ...gitLogArgs],
3232
workingDirectory: workingDirectory,
3333
);
34+
if (result.exitCode != 0) {
35+
throw ProcessException(
36+
'git', ['log', ...gitLogArgs], result.stderr, result.exitCode);
37+
}
3438
return ((result.stdout as String).trim().split('\n'))
3539
.where((message) => message.trim().isNotEmpty)
3640
.toList();

0 commit comments

Comments
 (0)