Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Git: How to push a branch to a different remote

Posted on 2012-03-25
3
Medium Priority
?
778 Views
Last Modified: 2013-11-25
Hi, experts,

I have an open source project, and I want to have my closed branch within this project. I can push it to a different remote, for example, I can have my open source branches on github, and my closed branches on bitbucket. Would that work? Is there a better way, perhaps with forking?

Thank you,
Mark

PS. Both projects are mine, I just don't want to open source some part of it.
0
Comment
Question by:kerzner
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 1

Author Comment

by:kerzner
ID: 37779757
Well, you can do this with forks, and perhaps that is what I should do.
0
 
LVL 24

Accepted Solution

by:
johanntagle earned 2000 total points
ID: 37780331
Both can work.  For the additional repo, the following should do:

git remote add -t branch_name name_for_other_repo other_repo_url
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Make the most of your online learning experience.
Q&A with Course Creator, Mark Lassoff, on the importance of HTML5 in the career of a modern-day developer.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question