Welcome to the CSC Q&A.
Get help and give help!
Write great code!
It is our choices... that show what we truly are, far more than our abilities.

Categories

+31 votes
asked in CSC285_Fall2018 by (8 points)

4 Answers

+15 votes
 
Best answer

A branch is a git pointer that allows you switch between different versions of your code. It allows for making changes independently from your other changes ... this was what I got from the vogella tutorial and I was still lost ish.

Found this https://www.atlassian.com/git/tutorials/using-branches

A branch represents an independent line of development. Branches serve as an abstraction for the edit/stage/commit process. You can think of them as a way to request a brand new working directory, staging area, and project history. New commits are recorded in the history for the current branch, which results in a fork in the history of the project.

answered by (785 points)
selected by
+5

Also, as a feature it allows you as a user make changes in a set of files without affecting the state of the files in your other branches ...

+17 votes

I think you should re-read all the materials from Reading Assignment 2 in order to get a full sense of it
(Particularly, http://www.vogella.com/tutorials/Git/article.html#using-branches would help)

answered by (8 points)
+16 votes

Just imagine that they are different versions of a program or some thing...

answered by (2.1k points)
+13 votes

It looks like you've already got some good answers about the overall concept. However, if you want some hands-on practice manipulating branches with the git command line, then you could also try the interactive simulators here: https://try.github.io/

answered by (12.2k points)
...