GitHub Repo Branch

From GM-RKB
(Redirected from GitHub Branch)
Jump to navigation Jump to search

A GitHub Repo Branch is a git branch in a GitHub repository.



References

2019

2013

2011

I would recommend using tags (tag tutorial)
From your master branch since you are done v1.0 add a tag called v1.0.
  git tag -a -m "Tagging release 1.0" v1.0
This way you can always come back to a specific version at any time by calling git checkout [tag_name]
Another common practice is to use branches to work on features until they are stable.
  git checkout -b [feature-branch]
That creates a new branch named whatever is in [feature-branch] and checks it out. Be sure to do this from where you want to start working on the feature (typically from master).
Once stable they can then be safely merged into master. From master run:
  git merge [feature-branch]
This way your master branch always stays in a working state and only completed items get added once ready. This will allow you to keep a working copy of the app at all times (ideally anyways) for testing, etc.
You could use branches for each version of the application however using tags makes it so you can't merge into another branch version by accident.

2010

  • http://nvie.com/posts/a-successful-git-branching-model/
    • … The repository setup that we use and that works well with this branching model, is that with a central “truth” repo. Note that this repo is only considered to be the central one (since Git is a DVCS, there is no such thing as a central repo at a technical level). We will refer to this repo as origin, since this name is familiar to all Git users.