This lesson is still being designed and assembled (Pre-Alpha version)

Intermediate Git Version Control: Glossary

Key Points

Introduction
  • Git version control records text-based differences between files.

  • Each git commit records a change relative to the previous state of the documents.

  • Git has a range of functionality that allows users to manage the changes they make.

  • This complex functionality is especially useful when collaborating on projects with others

Forks
  • A fork is a server-side copy of a repository

  • A fork can be created on Github through the Fork button in the top right

Branches
  • A branch represents an independent line of development.

  • git branch creates a new pointer to the current state of the repository and allows you to make subsequent changes from that state.

  • Subsequent changes are considered to belong to that branch.

  • The final commit on a given branch is its HEAD.

Remote Repositories
  • The git remote command allows us to create, view and delete connections to other repositories.

  • Remote connections are like bookmarks to other repositories.

  • Other git commands (git fetch, git push, git pull) use these bookmarks to carry out their syncing responsibilities.

Branching Models
  • A branching model is a pre-agreed way of merging branches into the main branch.

  • A branching model is needed when multiple contributors are making changes to a single project.

Merging
  • git merge --no-ff is the best way to merge changes

  • git merge --ff-only is a good way to pull down changes from remote

Advanced Logging
  • We’ve been introduced powerful logging commands

Identifying breaking commits
  • git blame can identify when a problem line was introduced.

  • git bisect can be used to binary search through git history to identify lines which first introduced a problem.

Tags
  • git tag allows us to mark a point we can return to.

  • A tag is tied to a commit.

Issue Tracking
  • Github includes an issue tracker for each repository where people can describe and discuss issues with code.

  • Issues can be opened, commented on and closed from the Github web interface.

  • Issues can also be closed in a commit message using ‘fixes’, ‘fixed’, ‘close’, ‘closed’ or ‘closes’ followed by a # symbol and the issue number.

Odd things to know about Files
  • (Large) binary files can grow the repository size immensely and make it unusable

  • git lfs is an extension that stores large files outside the Git data model

  • Use of Git LFS is discouraged in many scenarios.

Publishing and Citing Code

Glossary

FIXME