I am trying to push a React app I've been working on to git. I have never had this issue occur before, but apparently one of the babel packages is too big. This is the error I'm getting:
error: open("babel-preset-react-app/node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-nullish-coalescing-operator/node_modules/@babel/core/lib/config/validation/option-assertions.js"): Filename too long
error: unable to index file 'babel-preset-react-app/node_modules/@babel/preset-env/node_modules/@babel/plugin-proposal-nullish-coalescing-operator/node_modules/@babel/core/lib/config/validation/option-assertions.js'
fatal: adding files failed
Is it ok if I ignore this file? Why is the name so long that I can't push it to github?
Try this git config core.longpaths true
. It will allow git to handle long filenames.