Le message tiré d'un fichier avec -F, ou de la ligne de commande avec -m, ou depuis un objet commit avec -C est généralement utilisé sans modification.
The message taken from file with -F, command line with -m, and from commit object with -C are usually used as the commit log message unmodified.
Nous pouvons créer notre commit de base en utilisant la commande commit-tree, qui accepte juste un arbre et nous fournit un SHA-1 d'un objet commit orphelin tout nouveau.
We can create our base commit using the commit-tree command, which just takes a tree and will give us a brand new, parentless commit object SHA back.
Ce sont les informations élémentaires qu'un objet commit stocke pour vous.
Donc, ce que nous allons faire, c'est créer un objet commit initial comme base avec les instructions, puis rebaser les commits restant (quatre et cinq) dessus.
So, what we're going to do is create an initial commit object as our base point with instructions, then rebase the remaining commits (four and five) on top of it.
La première information indique qu'on définit un objet commit et la branche sur laquelle il se trouve, suivi de la marque qui a été générée, l'information du validateur et le message de validation et enfin le commit précédent, s'il existe.
The initial information states that you're defining a commit object and what branch it's on, followed by the mark you've generated, the committer information and commit message, and then the previous commit, if any.
L'objet étiquette (tag en anglais) ressemble beaucoup à un objet commit. Il contient un étiqueteur, une date, un message et un pointeur.
The tag object is very much like a commit object - it contains a tagger, a date, a message, and a pointer.
Pour créer un objet commit, il suffit d'exécuter commit-tree et de préciser l'empreinte SHA-1 d'un seul arbre et quels objets commit, s'il y en a, le précèdent directement.
To create a commit object, you call commit-tree and specify a single tree SHA-1 and which commit objects, if any, directly preceded it.
La tête courante est conservée dans le fichier.git/HEAD qui contient l'empreinte d'un objet commit.
The current head is kept in the file.git/HEAD, which contains a hash of a commit object.
La valeur retournée est une empreinte SHA-1 du nouvel objet commit que vous pouvez alors utiliser pour obtenir un objet Commit.
The return value is the SHA-1 hash of a new commit object, which you can then use to get a Commit object.