更新时间:2021-07-02 15:27:37
coverpage
Title Page
Second Edition
Copyright
Git Essentials
Credits
Foreword
About the Author
About the Reviewer
www.PacktPub.com
Why subscribe?
Customer Feedback
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the color images of this book
Errata
Piracy
Questions
Getting Started with Git
Foreword to the second edition
Installing Git
Installing Git on GNU-Linux
Installing Git on macOS
Installing Git on Windows
Running our first Git command
Making presentations
Setting up a new repository
Adding a file
Committing the added file
Modifying a committed file
Summary
Git Fundamentals - Working Locally
Digging into Git internals
Git objects
Commits
The hash
The author and the commit creation date
The commit message
The committer and the committing date
Going deeper
Porcelain commands and plumbing commands
Trees
Blobs
Even deeper - the Git storage object model
Git doesn't use deltas
Wrapping up
Git references
It's all about labels
Branches are movable labels
How references work
Creating a new branch
HEAD or you are here
Reachability and undoing commits
Detached HEAD
The reflogs
Tags are fixed labels
Annotated tags
Staging area working tree and HEAD commit
The three areas of Git
Removing changes from the staging area
File status lifecycle
All you need to know about checkout and reset
Git checkout overwrites all the tree areas
Git reset can be hard soft or mixed
Rebasing
Reassembling commits
Rebasing branches
Merging branches
Fast forwarding
Cherry picking
Git Fundamentals - Working Remotely
Working with remotes
Clone a local repository
The origin
Sharing local commits with git push
Getting remote commits with git pull
How Git keeps track of remotes
Working with a public server on GitHub
Setting up a new GitHub account
Cloning the repository
Uploading modifications to remotes
What do I send to the remote when I push?
Pushing a new branch to the remote
Tracking branches
Going backward – publishing a local repository to GitHub
Adding a remote to a local repository
Pushing a local branch to a remote repository
Social coding - collaborating using GitHub
Forking a repository
Submitting pull requests
Creating a pull request