Search code examples
node.jsmacosdropbox

How can I get Dropbox (on Mac) to always ignore node_modules?


I am using Dropbox for everything and it works perfectly — except from with projects including node_modules where it fucks everything up.

I have tried different solutions, and have a terminal shortcut "di" to tell dropbox to ignore the node_modules-folder etc. Sometime I forget running this, or the folder exists for long enough to put Dropbox in complete meltdown syncing 23,321,676,243,588,742 files.

I cannot see a single important usecase where I would need Dropbox to sync a folder named node_modules. How can I make it ALWAYS ignore all folders named node_modules, or in another way avoid these kinds of syncing problems?


Solution

  • 👋 I've done a quick Google search for you, since I've been looking for the same thing.

    There is an answer on the similar/same question on superuser: https://superuser.com/a/1527145

    And a comment to that answer by https://superuser.com/users/693355/panagiotis-simakis where he introduces his shell scriptthat utilizes files similar to .gitignore but for dropbox. Give it a try https://github.com/sp1thas/dropboxignore

    Let me know if it works!