Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Setting remote to a specific branch?

Benjamin Allison August 21, 2014
So I understand the value of branching, but one thing is confusing me. I have my local repo. I push changes to a remote, which has a post receive hook setup to write files on a website. So I create a branch (new-branch) to try out something. I edit files, commit, and push to the remote. Great. Problem is, while the repo on my remote is up to date, I guess it's still set to master,as the changes in new-branch aren't reflected on the site. How do I set the remote to a particular branch so that that branch is driving the post receive hook, and not just defaulting to the master branch? I would just merge on master but I'm not ready to as I'm still working out the kinks on the branch.

2 answers

0 votes
Graham Stewart August 22, 2014

While I can not answer your question specifically, I found that A Successful Git branching model written by Vincent Driessen http://nvie.com/posts/a-successful-git-branching-model/provided an explanation on how to create a workflow that handled separate branches for developement and production code.

There are also some excellent tutorials on different workflows with git on the atlassion website as well.

Graham

0 votes
Seth
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 21, 2014

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events