Skip to content

Commit

Permalink
fix: Add maxBuffer to expensive git commands
Browse files Browse the repository at this point in the history
Should be a fix for #253
  • Loading branch information
sammcj committed Nov 29, 2022
1 parent 27113d1 commit 3f93623
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
5 changes: 3 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30465,7 +30465,7 @@ class Git {
Synced local file(s) with [${ GITHUB_REPOSITORY }](https://github.com/${ GITHUB_REPOSITORY }).

${ PR_BODY }

${ changedFiles }

---
Expand Down Expand Up @@ -30623,7 +30623,8 @@ const execCmd = (command, workingDir, trimResult = true) => {
exec(
command,
{
cwd: workingDir
cwd: workingDir,
maxBuffer: '40mb'
},
function(error, stdout) {
error ? reject(error) : resolve(
Expand Down
2 changes: 1 addition & 1 deletion src/git.js
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ class Git {
Synced local file(s) with [${ GITHUB_REPOSITORY }](https://github.com/${ GITHUB_REPOSITORY }).
${ PR_BODY }
${ changedFiles }
---
Expand Down
5 changes: 3 additions & 2 deletions src/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ const execCmd = (command, workingDir, trimResult = true) => {
exec(
command,
{
cwd: workingDir
cwd: workingDir,
maxBuffer: 4194304
},
function(error, stdout) {
error ? reject(error) : resolve(
Expand Down Expand Up @@ -149,4 +150,4 @@ module.exports = {
copy,
remove,
arrayEquals
}
}

0 comments on commit 3f93623

Please sign in to comment.