Activity › Forums › Salesforce® Discussions › What does commit object contains in Salesforce?
Tagged: Commit Object, Git, Salesforce Code, Salesforce File, Version Control
-
What does commit object contains in Salesforce?
Posted by Prachi on August 10, 2018 at 5:59 AMWhat does commit object contains in Salesforce?
Parul replied 7 years, 7 months ago 3 Members · 2 Replies -
2 Replies
-
Hello Prachi,
A commit is described by a parent commit and a set of file modifications. This is enough to represent the version of the code at this commit. Indeed to find the code at this commit, you take the code from the parent commit and apply it the given set of modifications. This allows to keep a complete history of your code without having to store individually each version of each file. The file modifications are mainly add a line in a file, and delete a line. You can also rename a file, add a new file and delete a file.
A commit also contains informations about the author, the creation date and the message which was published with. A commit is identified by a hash, which is used in git commands to refer to this particular commit.
- [adinserter block='9']
-
A “commit” points to a single tree, marking it as what the project looked like at a certain point in time. It contains meta-information about that point in time, such as a timestamp, the author of the changes since the last commit, a pointer to the previous commit(s), etc.
Log In to reply.