Why is checking in files called a 'commit'?
The word "commit" can also mean to secure something for future use or for preservation. For example, "He committed the password to memory." When you "commit" your changes, you are locking them in as they are now for future preservation.
Consider also a version-control repository is a referential like databases are referentials.
And the term commit comes from data management, making a set of tentative changes permanent.
(Note that is makes a lot of sense for git, where you add tentative changes to the index with git add
, before recording them in the repo with git commit
)
A commit in the context of these version control systems refers to submitting the latest changes of the source code to the repository, and making these changes part of the head revision of the repository.
Thus, when other users do anUPDATE
or acheckout
from the repository, they will receive the latest committed version, unless they specify they wish to retrieve a previous version of the source code in the repository.