Garry,
I am sure there are more sophisticated mechanisms but here is what I do:
In our environment we have multiple sites.
The sites all share some common objects (Tables, Formats, Tcl Procs, etc.) as well as local objects (Xlates for example are almost always local).
In order to facilitate that we constructed a site which contains no integrations but just provides a directory structure to contain the common objects described above. In other words common Tcl procs reside in the common site’s tclprocs directory.
Then the using sites (where the integrations really reside) soft link to the appropriate object in the common site’s appropriate directory. Except for tclprocs – more on that later.
This allows us to maintain only one copy of the objects but have multiple uses.
Nearly all of our Tcl procs are constructed to be reusable by nature. In other words the procs are driven by arguments such that one proc can be used multiple times within a given site or any number of sites. Thus they need to be referenced from a common location.
Our procs do reside in the common site’s tclprocs directory BUT the soft link to that location is from the $HCIROOT/tclprocs directory. This is because Cloverleaf(R) will populate the pull down lists for selecting procs with entries from $HCIROOT/tclprocs AND the sites’s tclprocs directory. Thus we do not need soft links for common tclprocs in all sites.
One caveat though – when a new release comes the $HCIROOT/tclprocs directory gets rebuilt – meaning our soft links (and if not using soft links the procs themselves) disappear. With using soft links, all we need to do is rebuild the links in the $HCIROOT/tclprocs directory after upgrade but before turning any sites on.
I use UltraEdit to edit my Tcl procs. UtraEdit has an FTP option. But I maintain the originals on my PC and then FTP them. If they are new procs or need major upgrade, I FTP them to the site where I am testing and place them in that site’s tclprocs directory. Once they are tested and ready, they are moved to the common site and a soft link is made in the $HCIROOT/tclprocs directory, then a mktclindex is done, and the local copy is removed.
If they are modifed and not new, then all sites using the proc(s) in question either reload the proc(s) or the appropriate control (thread, process) is cycled to reload the proc(s).
Jim Kosloskey
email: jim.kosloskey@jim-kosloskey.com 29+ years Cloverleaf, 59 years IT - old fart.