mirror of
https://github.com/angular/angular-cli.git
synced 2025-05-15 18:13:38 +08:00
build: increase buffer size for DO_NOT_SUBMIT git diff
This commit is contained in:
parent
e8dff5718f
commit
c4df643c6d
@ -50,7 +50,10 @@ export default async function (argv: ValidateCommitsOptions, logger: logging.Log
|
||||
let errorCount = 0;
|
||||
|
||||
for (const fileName of files) {
|
||||
const diff = execSync(`git diff "${baseSha}..${sha}" -- "${fileName}"`).toString().trim();
|
||||
const diff = execSync(`git diff "${baseSha}..${sha}" -- "${fileName}"`, {
|
||||
// Increase the default buffer size by 100. Diffs can be quite large.
|
||||
maxBuffer: 100 * 1024 * 1024,
|
||||
}).toString().trim();
|
||||
|
||||
// This does not trigger itself because of the `b` in `\bDO_`...
|
||||
if (diff.match(/\bDO_NOT_SUBMIT\b/)) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user