You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have verified that the command is causing trouble is
git diff --name-only origin/master..HEAD
I committed by mistake my node_modules folder and now I want to remove it from my repository. Obviously, the list of files is big and the command above produces a lot of text. I could increase the maxBuffer but I have read the article on http://www.hacksparrow.com/difference-between-spawn-and-exec-of-node-js-child_process.html that does not recommend to do that. What do you think? Do you have anything against using spawn rather than exec to create the child process?
The text was updated successfully, but these errors were encountered:
Hi Gleb,
I am using your library to create hooks for git. Kudos for the good work. I am getting an error though:
pre-push Failed to check for commits. Cannot run the tests.
pre-push [Error: stdout maxBuffer exceeded.]
I think this is due to the limitation of the stdout maxBuffer that Nodejs defaults to 200KB, see https://nodejs.org/api/child_process.html#child_process_child_process_exec_command_options_callback.
I have verified that the command is causing trouble is
git diff --name-only origin/master..HEAD
I committed by mistake my node_modules folder and now I want to remove it from my repository. Obviously, the list of files is big and the command above produces a lot of text. I could increase the maxBuffer but I have read the article on http://www.hacksparrow.com/difference-between-spawn-and-exec-of-node-js-child_process.html that does not recommend to do that. What do you think? Do you have anything against using spawn rather than exec to create the child process?
The text was updated successfully, but these errors were encountered: