I have to maintain the same sources in 2 different TFS systems.
One is in the local network, the other is reachable over a VPN.
(So the other one is not always available.)
When trying to do the second mapping, TFS shows the error:
"The path X is already mapped in workspace Y" (which is correct).
I also tried to create a separate workspace, but this gives the same error.
I once created a workaround by mapping the same disk to another drive letter
(like "Z" and "Y"). But I'm wondering, if this is really without problems, with respect to the temporary files TFS puts on the disk.
So my question is: Is there an official way to map the same folder to 2 different TFS systems?
Unlike Git, it's not possible to map two different TFS sever folders(also two TFS systems) to the same local filesystem path, or to overlapping filesystem paths. It's also regardless of whether the two mappings are in the same workspace, or in two different workspaces.
Workspaces and their mappings are managed and stored on the TFS server, the server is capable of enforcing this restriction across all workspaces on the same machine.
Related
I have a tfs on visualstudio.com and I access it from my home and work by using same live.com login. These two computers are named the same (even the full paths to the solution folder are the same) and thus the workspaces got named the same. Now, when I try to do get-latest, it never gets me anything whether I am at home or at work because it probably thinks it already has all latest files in it. Assuming my hypothesis is right, is there a way to make these look distinct to the tfs ? The only way to get-latest for me is to get-specific and mark the second tick, but it also overrides my web.config file (which is not exactly the same since the connection strings are a bit different) which is excluded from the project for obvious reasons (to not be locked/changed since each user needs it different for their own sql server connection string)
Workspaces are uniquely identified by workspace name and username. However TFS only sends a list of "local" workspaces to each machine that you use based on its name. If you have two machines with the same name then they both workspaces will be listed as local to that machine and Visual Studio will get confused and your workspaces will be corrupted. To solve this issue you need to rename one of your computers.
You can work around it without renaming the computers by creating two workspaces with names like "home" and "work". You will however need to make really sure that you only use one in each location as crossover will give you the same problem as above.
How can I have the same user on multiple virtual machines be able to share the same workspace folder? Should each user create a "public workspace" or should we change our practice?
A bit of background :
when we worked with VSS and VB6 / ASP each user would map to a personal share (w:) which would map to \server\username\ . Every machine mapped w:\ to the user, so that when the user moved from one virtual machine to another they would find the state of checked in / out to be consistent. (at worst they'd get a message from VSS saying you checked this out on xxx and now you're checking in on yyy... -> and they'd just click ok)
Now we're moving to TFS and we're finding that workspaces are specific to each machine (check out on machine A, and find that machine B is unable to edit)
I was looking at Public Workspaces, though that seems to be designed to resolve a different task I thought it might cover the issue... So I was wondering if this was a safe practice and if anyone has actually tried it, or if we'd be heading for a major trainwreck.
Thanks!
My analysis: Trainwreck.
Each user/machine should have their own local (ie: non-network) path for the workspace.
I have a number of SSIS packages spread throughout TFS, e.g. \Imports\impSSIS01\\, \OtherPackages\Exports\expSSIS02\\, etc. Anytime I open up any of those, I want the working directory to be E:\SSIS\, e.g. E:\SSIS\impSSIS01\\*.\*, E:\SSIS\expSSIS01\\*.\* When I try to set up my workspaces like that though, I get the error:
The path E:\SSIS is already mapped in workspace PC-MYCP01
I don't care if it's already mapped. I know it's already mapped. I want it to be already mapped. Just let me map it.
(Also, does this mean no one else on my team could use E:\SSIS\? I hope not, it's a shared drive we all need to use.)
Have you tried removing all your mappings and then map the root of your Tfs collection to e:\ssis. That way getting latest on a sub folder will extract the contents to a folder relative to e:\ssis.
Download the free Team Foundation Sidekicks 2010. It provides a convenient way to delete and modify workspaces.
Is it possible to add your projects/source to two different TFS servers?
If possible it would be very handy to synchronize my local TFS server with TFSPreview.
This is definitely not supported. TFS stores cache of your local workspaces and will never allow you to map the same folder to two different servers. This is how you can work with tf.exe without specifying server switch every time.
Very simple solution for you is to mirror one workspace with robocopy in another directory. Before you start doing something on your own please look at http://tfsintegration.codeplex.com/. TFS product team is afaik using it exactly for purpose of synchronizing between 2 servers.
we have 2 branches of code in tfs 2010 such as enhancement and support
Most of the developers work on enhancement as well as support.
Now, We want to create two different work spaces and map it to one local folder as we have all our virtual directories mapped to that local folder and dll registered from that location.
However, TFS does not allow this!! So what is the alternative? Also
mapping to two different local folders will occupy more spaces on each individual developer's machine.
This is not supported. As Stuart mentioned in his question - TFS is not able to decide where to do check-in, if you try to check-in your changes on one file mapped from two branches.