From the course: Learning Git and GitHub

Unlock this course with a free trial

Join today to access over 24,800 courses taught by industry experts.

Understanding Git environments

Understanding Git environments

From the course: Learning Git and GitHub

Understanding Git environments

- [Instructor] Now that we've created our first commit, let's dig into how Git takes care of things. If you take a look at what you got when you issued the log command, you should see something like this. Our sole entry starts off by listing the commit hash. This is a unique ID for the commit. Next to that hash Git shows us that the head is currently in our main branch. Git uses branches to organize project. Each branch is like an alternate reality for the project. The head always points to the current reality which is called a branch. So this is the current branch we're working on. Now by default, this branch is called Main, but older versions of Git use the term master. On the next slide you can see the name of the author and email. It should be the same as what we configured with the Git config command. Next it shows the date the commit was made, and finally whatever message you wrote when committing the file. Now…

Contents