0

I'm working on a CakePHP project, whose source I have cloned via GitHub. My own code is located inside the CakePHP folder.

I would like to be able to push my code into it's own repo in GitHub, while being able to pull any CakePHP update from Github without this deleting or overwritting my code.

Is this possible?

Thanks!

Sandy
  • 2,572
  • 7
  • 40
  • 61

1 Answers1

1

Yes, you can do that directly by cloning the CakePHP code, and then cloning your own code inside the CakePHP working tree. In this case git will report your directory as untracked when working inside the CakePHP code.

Optionally, you can add the name of your directory in a .gitignore file inside the CakePHP root directory, but unless you have commit rights for CakePHP or use your own fork, you won't be able to do that. So an alternative is to add it in the .git/info/exclude file which only exists in your local clone.

Sergiu Dumitriu
  • 11,455
  • 3
  • 39
  • 62
  • See this answer to address the issues with your solution http://stackoverflow.com/questions/1753070/git-ignore-files-only-locally – Alex Brown Aug 30 '12 at 04:39