Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I am building an app using Code Igniter, it is being based on CI-Bonfire.

I am pulling in the dev branch of CI-Bonfire using git, I want the entire project to be git controlled as well, but I want to be able to just pull the latest changes from the dev branch of CI-Bonfire, but push my entire app to a different repository.

All changes that I make to the files that come from bonfire will be config changes, so all pulls will be able to merge automatically.

Is this possible?

share|improve this question
add comment

1 Answer

up vote 6 down vote accepted

Let's see if I understand you correctly: You want to have your own git repo, containing all the bonfire code. You then want to make your own changes and NOT push them back to the bonfire-repo, but to your own. And from time to time, you still want to pull in the recent changes from the bonfire-repo?

That sounds pretty much like the normal git workflow, just without merging your changes back to original repo. Of course it's possible.

I haven't actually tested it, but it should be something like this:

  1. Create the repo: git init
  2. Add a remote for the bonfire-repo: git remote add bonfire https://github.com/ci-bonfire/Bonfire.git
  3. Pull in the code: git pull bonfire developer (or use the master branch or whatever)
  4. Create project on Github (not a fork of the bonfire-repo, just a new, empty project)
  5. Add a remote for your own repo: git add remote origin git@github.com:<User>/<Project>.git
  6. Make your changes, commit them
  7. Push to your own repo: git push origin master (or whatever branch you like)

Now, if you want to pull in the latest changes from bonfire, just do step 3. again whenever you want. And for your own changes, just keep doing steps 6. and 7.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.