Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

If I have a program and a set of example data that I want to distribute on SVN (separately so people who are familiar with the code need not get the example data with it), what's the best way to do this? Can I put that in a "branch"? Or should I put the code + examples in the branch and somehow keep the trunk and branch code synchronized?

Thanks! SVN noob

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

You put the code and examples in two separate directories with a common parent. So your project might look like:

 .../myproject/
   myproject-code/
   myproject-examples/

Subversion lets one check out subdirectories of a repository. For example, someone who wanted just the code could do this:

$ svn co http://example.com/svn/myproject/myproject-code/

Someone who wanted both would check out the parent.

share|improve this answer
    
Thanks -- I already have it running with program/trunk, program/branch, ... is there a way to change it now? Also, is it possible to check out the examples into subdirectories of the program/ directory locally? Or have to write a separate script -- I'm distributing this to scientists (i.e. non-programmers) so trying to keep it simple. Thanks! –  crippledlambda Dec 3 '10 at 19:27
    
You can always rearrange your repository. If you have program/trunk, program/branch, you can add program/trunk/code and program/trunk/examples, or you can put the examples at the top level if they're not version dependent (e.g., program/trunk, program/branch, program/examples). Or you could just include the examples with the code, which really seems easiest unless they're really large. –  larsks Dec 3 '10 at 19:36
    
Much appreciated! –  crippledlambda Dec 3 '10 at 19:53
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.