From the course: Git Essential Training
Unlock this course with a free trial
Join today to access over 24,700 courses taught by industry experts.
Solution: Make a change and revert
From the course: Git Essential Training
Solution: Make a change and revert
(bright music) - [Instructor] So how did it go? Let's see a solution to our challenge. So I have already created important_File.md and added a line. Now I am going to commit this to my local repository. I'll first add it to the staging area and then I'll use git commit -m "creates Important File md". All right. I will add an extra line, save that, and I'll create a new commit. So I'll press Enter and use git commit and commit this file as well. Now I am going to create a folder and I'll add the file Important File to the Important folder. Again, I will create a commit, so I'll add the change and I'll commit. As you can see, Git sees this as a rename of Important File to Important File in the Important folder. Remember that at any point you can check your process with git status. As we can see here, I am now ahead of the remote branch, so I'll push everything. There we go. Now let's review our git history. I'll press Clear and use Git log --oneline to get an overview of the history of…
Contents
-
-
-
-
-
-
-
(Locked)
Git status2m 24s
-
(Locked)
Edit a file and view changes4m 14s
-
(Locked)
Delete files1m 35s
-
(Locked)
Rename files2m 18s
-
(Locked)
Working with folders3m 5s
-
(Locked)
Undo your changes2m 20s
-
(Locked)
View commit history4m 5s
-
(Locked)
Go back in Git history1m 52s
-
(Locked)
Revert a commit1m 55s
-
(Locked)
Make use of the GUI of Visual Studio Code2m 51s
-
(Locked)
Challenge: Make a change and revert51s
-
(Locked)
Solution: Make a change and revert2m 22s
-
(Locked)
-
-