Merged directories: How to? Impossible?
Hello experts,
I have a problem here which I can't quite get around with Team System: For various products, we have HTML files and some form files, of which some are exclusive for a product, and others are shared between several products.
Using VSS, we used to first "get" all the shared content into a directory in the workspace, and then "get" all the product specific content into that same directory. VSS usually managed to remember the paths for both client paths, making it possible to check-out and -in using the VSS client, in that merged directory.
If you try to do the same using the TS Client, it will cry out loud, telling you that the local path has already been mapped to another place on the Foundation Server.
Any thoughts on this? (Simple) Workarounds?
Best regards,
Martin
Hi there,
Let's say you have folders $/root/shared and $/root/productSpecific. If i understood you rightly, you used to map both folders to same client directory and then use get latest to get the files.
As far as I can judge, if you map $/root/shared to specific local directory in TFS in specific workspace, TFS will not allow you to map any additional server path (for example, $/root/productSpecific) to that directory. For what it is worth, it will also not allow you using that client directory in different workspace mapping.
But what you can do, you can map $/root directory to some client local directory, and then you will have both shared and productSpecific folders mapped to local paths. Does it solve your problem?
Cheers, Curedone
Thanks for answering, curedone, but unfortunately, it does not solve my problem. We would like to keep the HTML and Forms in a rather flat directory structure. Otherwise, we would have a huge directory tree just for the HTML content, and we would have to work with relative links having tons of http://'s. This might be ok on the developer's computer, but deploying that to the customer would be quite a mess. Additionally, we already have a lot of HTML content which does not use links like that...
TFS was not designed to work the way you describe - it is a side affect of the workspace being much smarter and keeping track of version etc.
It would be fairly easy to knock up a script using the command line client (tf.exe) to get the files into two seperate directories then copy them into a unified one for testing - however the developers will still have to work on the files in the individual directories when editing them.
If you really wanted to hack around things then you could use something like Junction from SysInternals to create a symlinked directory - however I would STRONGLY advice against that as you would just be hacking around code that was deliberately put in to stop you getting in a mess.
You could also set up something like CruiseControl.NET to automatically merge files on a common server somewhere everytime a check-in was performed, making things easier to test.
If you need help with the command line client script, post back and I'll be glad to help.
Martin.
Martin,
Thanks for answering. It looks as if we really have to think things over here... The script/batch file was the obvious solution, but as a fellow developer put it: "I'd like Team System to assist me, I don't want to use another workaround script."
I will definitely give CruiseControl.NET a look, it sounds interesting. Thanks for the link!
Martin
Yeah - TFS assists you in many other ways - but is a very different beast to VSS and so has to be used differently unfortuneately.
The CCNET source control plugin to TFS is available here. I'll be posting an updated version shortly. You can also roll your own CI server if you want, but as you don't really need to full power of TeamBuild - CC.NET will work just great for you.
Good luck,
Martin.