getRecentCommitMessages: return empty array if no commits (#222)
This commit is contained in:
Родитель
8ee82550b2
Коммит
58266b0384
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
"type": "patch",
|
||||||
|
"comment": "getRecentCommitMessages: return empty array if no commits",
|
||||||
|
"packageName": "workspace-tools",
|
||||||
|
"email": "elcraig@microsoft.com",
|
||||||
|
"dependentChangeType": "patch"
|
||||||
|
}
|
|
@ -93,7 +93,10 @@ export function getRecentCommitMessages(branch: string, cwd: string) {
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
|
||||||
return results.stdout.split(/\n/).map((line) => line.trim());
|
return results.stdout
|
||||||
|
.trim()
|
||||||
|
.split(/\n/)
|
||||||
|
.map((line) => line.trim());
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
throw new GitError(`Cannot gather information about recent commits`, e);
|
throw new GitError(`Cannot gather information about recent commits`, e);
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче