-
Notifications
You must be signed in to change notification settings - Fork 448
TFVC: Team Project is not identified when workspace is mapped at Team Project Collection root #175
Comments
Hi @eogas, thanks for trying out the extension! Yeah, you've run into a case where we had to decide what to do when we can't get the team project out of the workspace. We felt that most folks would map at least a single folder into their workspace that included the team project so we could parse it from there (and that's what you've seen when you map it one level deeper). If more than one team project is mapped into the workspace, I believe we default to the first we find. However, there's also the case where you can map $/ but that doesn't provide us with the team project name we need (and I believe this is the situation you're in). In this case, perhaps we should provide a way for you to indicate (perhaps through a setting?) which team project to use. In this case, you would be able to set up a workspace setting for each of your sub-folders that would tell us which team project to use. As you opened each folder (you'd have to open the individual folder for that to work) we'd use that team project. For the root folder where you mapped $/, you'd just have to pick one. BTW, can you describe how this error manifests itself? |
This is correct, I generally just map $/ rather than specific team projects.
Yes, this is the behavior that I expected. So as an example, if I map There isn't any error displayed in the editor, it just doesn't recognize the directory as being version controlled. With debug logging turned on, I can see that the extension just isn't resolving the Team Project name. I have lines like this:
|
I have the same issue. I mapped the team collection and cloaked all team projects, that I am not interested in. The extension shows the first project as current team project, even if I work in a different one. Modified files outside the workspace root of VS code are displayed as changes.
Can you determine the team project by comparing the workspace root (in Visual Studio Code) with the paths shown in the output of (I am using Forgot to mention that I am using Local Workspaces with TFS on-prem. |
Thanks @eogas. Interesting idea @MindGirl... Maybe we really need a combination of the two? If we can't find the team project via workfold, we could try the top-level folder in the opened VS Code workspace. Since you can still map $/TeamProject1 to a folder other than /TeamProject1, if we took the feature this far, we could then check some sort of user-provided setting. |
Closing this as a duplicate of #179 (the more active issue). |
When working with TFVC, I usually map my workspace at the root of the entire Team Project Collection, then selectively bring in the Team Projects that I'm working in. It looks like the extension doesn't currently support this workflow. Even if I specifically open the child directory where the root of a Team Project is mapped, the extension cannot identify the Team Project name. If I map my workspace one level deeper, at the root of a Team Project instead, everything works as expected.
I don't know if it makes a difference, but this is with an on-prem instance of TFS 2015 with Update 3.
The text was updated successfully, but these errors were encountered: