TL / DR : There are no rules. But open source projects - > presence of pull requests and patches - > smaller commits that can be easily reviewed by other developers. Commercial projects - > Larger commits to implement all aspects of a particular feature (even if the developer locally does multiple commits). Again, there are no rules, but I could see this difference in behavior in practice between the two types of projects.
While there are no rules defined, mature open source projects with multiple collaborators often work with finer granularity of commits . This is due to the very nature of the project. In open source projects, several external developers pull requests and / or submit small patches to fix small bugs or add small functionality to the project. The idea here is that commits are not only representative, more self-contained, and easily revisable by a project developer. Minor Commits are faster to review and give less headaches to who will integrate your code into the main repository (possibly long after you've submitted the patch ).
Even the "core" team of a project, with push permission in the main repository, usually works with finer granularity of commits . Large work units are usually well subdivided between the various modules, and later subdivided into smaller tasks. The result is that there are more tasks, each one more "punctual"; soon commits are made, each with less code.
On commercial projects, it is equally common for a developer to make several small commits locations (say, a feature ), but before the push to the main repository, it is common practice to do a squash of those commits , giving the impression of a single large commit that solved a certain task / problem. The main point here is that the granularity of the tasks are larger, and there is an effort to make the repository "cleaner".
Each strategy has its advantages. Frequent and small Commits represent better the actual flow of development, however, thicker granularity and history rewriting make the commit tree cleaner. There are good arguments from the school "Make commit fast, always commit, never rewrite history" as well as school "Keep your central repository clean". The choice is entirely yours.