
A commit run with no extra arguments records what the index holds and nothing else. git add is the command that puts…

A feature branch usually ends up with a few commits nobody will want to read later.…

A plain git commit records the contents of the index and nothing else. The index is…

Git keeps a project’s full change history as commits in a content-addressed object database, and that…

Most people meet the word origin by pasting a command from a README, and they never…

Git will let a team do almost anything with its branches. It has no opinion on…

Most of the confusion around git commit comes from assuming it saves your files. It saves…

Most people who run git prune by hand are surprised by how little it does. It…

git merge takes the commits from one branch and puts them into the branch you have…

Putting an API key in a repository takes about four seconds, and getting it back out…

Before you type anything, work out which way the commits need to travel. Pushing sends your…

Reverting to a previous commit in GitHub mostly comes down to git revert or git reset,…

GitHub’s web interface can’t delete a commit. The closest thing is a Revert button on merged…

To host a site on GitHub you need a repository with an entry file such as…

Open Settings, go to Account, click Change username, and pick a name nobody else holds. Personal…

You merge in Git from the branch that should receive the changes. Check out the target…

The green merge button doesn’t look the same on every repository. Some show one option, some…












