Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8090343
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T19:41:14+00:00 2026-06-05T19:41:14+00:00

Scenario: On the github exists the user guru and his primamy repository for the

  • 0

Scenario:

  • On the github exists the user “guru” and his primamy repository for the project called “bigsw”. This primary repo has several branches. (“rel1”, “rel2”, “master”)
  • this project has 2 forks made by user1 and user2.
  • Each of the abobe forks has the same branches as the primary repo, plus one different branch what contains their particular work. So, user1 forked the bigsw and created a branch called “utf8” and user2 created a branch “mongo”.

  • now i want join to the project, and for my work I need the following branches:

    • guru/bigsw:master
    • user1/bigsw:utf8 (read as: USER/REPO:BRANCH)
    • user2/bigsw:mongo

What should be the recommended workflow?

My idea is:

  1. fork the guru/bisgw on the github (so will get myname/bigsw)
  2. git clone git://github.com/myname/bigsw (get a local copy)

  3. want keep synced local copy of user1/bigsw:utf8 branch and similarly want a copy of branch “mongo from user2’s fork. So, I don’t need clone the full repo from user1 and user2 only one branch from each. Somewhat like:

    • git remote add user1 git@github.com:user1/bigsw.git
    • git fetch user1
    • git checkout -b utf8 user1/utf8
    • and similarly for user2’s mongo repo (i’m not sure with the first two commands)
  4. git checkout -b i18n (to create MY own branch – where I will make my changes)
  5. edit the sources (and i hoping than after the previous command they will automatically “going” into “i18n” branch)
  6. git push origin i18n (to push my changes to github to myname/bigsw:i18n branch)
  7. and sometime in the future will submit an pull request for my i18n branch /don’t know how, but don’t need it yet ;)/

Is the above an correct workflow? If yes, questions:

  • how to clone user1’s branch “utf8” and user2’s “mongo” branches into my local machine – Are the commands in 3.) correct?
  • how to keep in sync all (so i want in my local machine synced branches from all above) – my changes will be only in my branch “i18n”.

I’m total newbie for git/github – and unfortunately need start with this complicated model(at least for me). I learned something digging into https://help.github.com/ , but not understand all “git philosophy”.

I was already read:

  • https://stackoverflow.com/a/5458814/869025 (this helps a lot)
  • https://stackoverflow.com/a/9153737/869025 – giving some ideas, but i’m not sure
  • How to combine two branches from two different repositories in a single repository?
  • Forking vs. Branching in GitHub
  • git Merging same directory of two different repositories
  • https://help.github.com/

but still wandering in the dark… 🙁

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T19:41:17+00:00Added an answer on June 5, 2026 at 7:41 pm

    Generally nice, but I have a few suggestions.

    I would leave out the git checkout -b userX userX/branch calls. Instead I would make sure I’m in the original branch by guru and create a local branch where you merge the two remotes together like this:

    git checkout -b utf8-mongo
    git merge user1/utf8
    git merge user2/mongo
    

    You will probably face merge conflicts which may look scary on the first sight, but you’ll evenutally find your way through them (look up guides on how to resolve merge conflicts and have talkback with the authors if unsure which change to prioritize).

    Then you can create your own branch off that using:

    git checkout -b i18n
    

    just as you suspected. Do your changes and obey to the rule commit early, commit often. Whenever you want to pull in changes from all the upstream branches, you do the following:

    git checkout utf8-mongo
    git pull guru/master
    git pull user1/utf8
    git pull user2/mongo
    

    Resolve any merge conflicts you have there like above, and then switch back into your branch and get the new changes:

    git checkout i18n
    git merge utf8-mongo
    

    The rationale behind splitting the branches is that merge conflicts are ugly to manage and you might in the future discard your branch and start from scratch. In that case you would not want to do all the merging of the others branches again, so you save them in a separate one.

    When doing a pull request using githubs web interface, you only request to pull from your branch i18n. People (i.e. guru) might be unhappy though as you pulled in a lot of other peoples branches, which may not be ripe enough yet to be merged into his own branch. You may need to have some mail contact to coordinate that pull. The best is probably to have a healthy communication with the devs right from the start.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Consider the following scenario: Someone has a project on Github that might be updated
I got this scenario: I created a Git repository. $ git init Cloned an
Take this scenario: I decide to 'fork' a codebase on github.com, and start doing
Scenario: At our company, we have enabled httpCompression for our website. This website (call
Scenario: Windows server in a AD domain hosting a Subversion repository using SVNSERVE only
Scenario: User is viewing a screen with an image and some accompanying text in
Scenario: The user is entering a date in an NSDatePicker in its textual form
Scenario: A simple html page exists with few buttons on Top (e.g. day, week)
I have some queries with following scenario on github. consider there is one organization
I cloned a repo using its GitHub read-only URL onto my team's staging server.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.