0

Is it possible update external files from a child project and then sync those changes back to other projects?

In the example below, two projects receive files from a "Common" project via svn:externals. I'm trying to find out if the developers working on Project A and Project B are able to directly update those files and have them replicate into the other project.

Example structure:

/svn
    /Common
        /scripts        <- main source folder
            scriptA.js
            scriptB.js
    /ProjectA
        /scripts
            /common      <- external points to source
                scriptA.js
                scriptB.js
    /ProjectB
        /scripts
            /common      <- external points to source
                scriptA.js
                scriptB.js

I've been looking for this answer for a while. None of the articles I find touch on this...

https://stackoverflow.com/questions/1535477...
https://www.simple-talk.com/...

Community
  • 1
  • 1
G. Deward
  • 1,542
  • 3
  • 17
  • 30

1 Answers1

0

All you need to do is: modify your externals in project A, then commit those changes, and then update project B.

There are 2 things you should be aware of:

If you want to commit changes that you've made in one or more of those external working copies, you must run svn commit explicitly on those working copies—committing on the primary working copy will not recurse into any external ones - more details here: http://svnbook.red-bean.com/en/1.0/ch07s03.html

Make sure your externals folder in project B is not tied to explicit revision, otherwise, svn update on project B will not pull latest changes - more info here (under "Use explicit revision numbers"): http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-dug-externals.html

Ivan Jovović
  • 5,238
  • 3
  • 29
  • 57