3. Putting the project under version control

Conclusion and next steps

Now that we've learned how to save new changes to the repository, let's see how we can revert unwanted changes in our working tree. Oh, wait, I almost forgot...

Quiz time!

Quiz yourself

1/6: What command initializes a new Git repository in the current directory?
2/6: What is the working tree in Git?
3/6: What does the git add command do?
4/6: What does the -m option do when used with git commit?
5/6: Why is it beneficial to split independent changes into separate commits?
6/6: What does a clean working tree mean?

Amazing work! In the upcoming chapter, we'll explore how to undo changes and revert to previous versions of your project. Get ready to become a Git time traveler!

Next step
Wanna try the Story mode?
Take the course as it was meant to be taken: bite-sized progression, focused linear order, gradually unlock Gitopedia entries. Continue with real Git in VS Code/Cursor at any time.
Story mode
FREE
but requires sign-in
© 2024-2026 GitByBit.All rights reserved.