I recently forked a Git repository, and locally I created a project in my IDE to compile with.

My IDE creates a variety of artifacts that I would like to keep saved somewhere. The obvious place would be in the VCS. If I add these files then they will be in the history for my fork. If i want send a pull request to merge upstream I wouldn't want these files included.

What would be a recommended workflow for managing these changes that I would never want to go upstream.


Structure your project so that it sits in a directory (and builds all files) outside of the source directory (such as [project root]/build) and exclude that directory in .gitignore.

This is the process that CMake uses (see "out-of-source builds" in their docs). Of course, you could always introduce yourself to CMake and build it into the project's pipeline. I'm sure the authors would love you for it ;)

| improve this answer | |
  • yeah, gitignore on the "out-of-source" files is what I have currently. – sylvanaar Nov 5 '11 at 18:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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