6h 26m – Beginner
The course shows how to use Git, the popular open-source version control software, to manage changes to source code and text files. Using a step-by-step approach, author Kevin Skoglund presents the commands that enable efficient code management and reveals the fundamental concepts behind version control systems and the Git architecture. Discover how to track changes to files in a repository, review previous edits, and compare versions of a file; create branches to test new ideas without altering the main project; and merge those changes into the project if they work out. The course begins by demonstrating version control in a single-user, standalone context, before exploring how remote repositories allow users to collaborate on projects effectively.
Topics include:
Exploring the history of version control
Installing Git on Mac, Windows, and Linux
Initializing a repository
Writing useful commit messages
Understanding the Git three-tree architecture
Tracking when files are added, edited, deleted, or moved
Viewing change sets and comparing versions
Undoing changes and rolling back to previous versions
Ignoring changes to select files
Creating and working with code branches
Merging branches and resolving merge conflicts
Stashing changes for later
Working with hosted repositories and remote branches
Developing an effective collaboration workflow
Introduction – 2m 46s
Introduction – 1m 7s
How to use the exercise files – 1m 39s
1. What is Git? – 20m 24s
Understanding version control – 4m 48s
The history of Git – 7m 58s
About distributed version control – 5m 4s
Who should use Git? – 2m 34s
2. Installing Git – 26m 12s
Installing Git on a Mac – 3m 44s
Installing Git on Windows – 5m 37s
Installing Git on Linux – 1m 30s
Configuring Git – 7m 29s
Exploring Git auto-completion – 5m 35s
Using Git help – 2m 17s
3. Getting Started – 15m 49s
Initializing a repository – 1m 58s
Understanding where Git files are stored – 2m 34s
Performing your first commit – 2m 4s
Writing commit messages – 5m 22s
Viewing the commit log – 3m 51s
4. Git Concepts and Architecture – 17m 44s
Exploring the three-trees architecture – 3m 57s
The Git workflow – 3m 15s
Using hash values (SHA-1) – 4m 7s
Working with the HEAD pointer – 6m 25s
5. Making Changes to Files – 25m 52s
Adding files – 5m 59s
Editing files – 3m 56s
Viewing changes with diff – 3m 35s
Viewing only staged changes – 2m 28s
Deleting files – 5m 29s
Moving and renaming files – 4m 25s
6. Using Git with a Real Project – 19m 18s
Introducing the Explore California web site – 2m 2s
Initializing Git – 3m 48s
Editing the support phone number – 6m 20s
Editing the backpack file name and links – 7m 8s
7. Undoing Changes – 38m 45s
Undoing working directory changes – 3m 49s
Unstaging files – 2m 37s
Amending commits – 4m 50s
Retrieving old versions – 4m 7s
Reverting a commit – 3m 12s
Using reset to undo commits – 3m 44s
Demonstrating a soft reset – 4m 8s
Demonstrating a mixed reset – 4m 7s
Demonstrating a hard reset – 5m 8s
Removing untracked files – 3m 3s
8. Ignoring Files – 27m 22s
Using .gitignore files – 8m 23s
Understanding what to ignore – 4m 47s
Ignoring files globally – 4m 49s
Ignoring tracked files – 5m 26s
Tracking empty directories – 3m 57s
9. Navigating the Commit Tree – 26m 51s
Referencing commits – 4m 52s
Exploring tree listings – 3m 46s
Getting more from the commit log – 7m 38s
Viewing commits – 4m 4s
Comparing commits – 6m 31s
10. Branching – 39m 35s
Branching overview – 4m 56s
Viewing and creating branches – 2m 57s
Switching branches – 2m 58s
Creating and switching branches – 4m 53s
Switching branches with uncommitted changes – 3m 26s
Comparing branches – 4m 28s
Renaming branches – 2m 28s
Deleting branches – 4m 18s
Configuring the command prompt to show the branch – 9m 11s
11. Merging Branches – 28m 32s
Merging code – 3m 11s
Using fast-forward merge vs. true merge – 6m 49s
Merging conflicts – 7m 26s
Resolving merge conflicts – 7m 5s
Exploring strategies to reduce merge conflicts – 4m 1s
12. Stashing Changes – 14m 34s
Saving changes in the stash – 4m 5s
Viewing stashed changes – 2m 39s
Retrieving stashed changes – 4m 24s
Deleting stashed changes – 3m 26s
13. Remotes – 1h 5m
Using local and remote repositories – 6m 38s
Setting up a GitHub account – 5m 39s
Adding a remote repository – 4m 0s
Creating a remote branch – 4m 3s
Cloning a remote repository – 4m 26s
Tracking remote branches – 4m 5s
Pushing changes to a remote repository – 5m 8s
Fetching changes from a remote repository – 5m 47s
Merging in fetched changes – 4m 50s
Checking out remote branches – 3m 22s
Pushing to an updated remote branch – 2m 6s
Deleting a remote branch – 3m 8s
Enabling collaboration – 3m 40s
A collaboration workflow – 8m 43s
14. Tools and Next Steps – 16m 23s
Setting up aliases for common commands – 5m 14s
Using SSH keys for remote login – 2m 56s
Exploring integrated development environments – 1m 4s
Exploring graphical user interfaces – 4m 32s
Understanding Git hosting – 2m 37s
Conclusion – 55s
Goodbye – 55s