How to use Visual Studio's TFVС local workspace in Rider

Rider is able to import TFS workspaces created by Visual Studio. Particular actions required to import a workspace depend on the Azure DevOps plugin installed.

As a prerequisite, you’ll be required to install the Team Explorer Everywhere command-line client (TEE-CLC release), and configure a path to it in Rider Settings | Version Control | TFVC | Classic TF command-line client (choose tf.cmd file on Windows, and tf file on macOS and Linux).

Azure DevOps 1.161 and newer

Local workspace

  1. Open a solution that is under Visual Studio version control.
  2. Select the main menu item VCS → Enable Version Control Integration… and select TFVC.

Server workspace

  1. Run the following command in the command line (as described here and here):
    tf.cmd workspaces /collection:<collection-url>
    (this command will update the Team Everywhere command-line client workspace cache, so it will know about your workspace)
  2. Open your solution in Rider.
  3. In case the workspace wasn’t imported automatically (a TFVC tab didn’t appear), select the main menu item VCS | Enable Version Control Integration… and select TFVC.

Azure DevOps 1.160 (only local workspaces are supported)

  1. Open a solution that is under Visual Studio version control.
  2. Select a main menu item VCS | Enable Version Control Integration… and select TFVC.

Azure DevOps 1.159 and older (only local workspaces are supported)

  1. Run the following command in the command line (it is described here and here):
    tf.cmd workspaces /collection:<collection-url>
  2. Open your solution in Rider.
  3. Make sure that the tf.cmd tool is specified in Settings | Version Control | TFVC.
  4. Call VCS | Enable Version Control Integration.
  5. Go to VCS | TFVC | Manage Workspaces, select your server, and press Reload workspaces.
  6. Select the workspace that you use in Visual Studio and press Edit.
  7. You will see the OAuth window. Sign in to your account.
  8. After that, press Save Workspace and close the Manage TFVC window.
  9. After all, you will see a repository in Settings | Version Control | Team Services / TFS, and your project is now ready for working with VCS in Rider.
9 comments
Comment actions Permalink

If you use a new workspace you need to map remote and local folders by running the command 

./tf workfold /map '$/<your remote project folder>' <local folder> /collection:<collectionUrl> /workspace:workspaceName 

the <local folder> should be your solution folder with .sln file inside.

Do this step after the second step in this post.

Edited by Sofia Byzova
0
Comment actions Permalink

Since release of Azure DevOps plugin v1.160, only items 1, 3 and 4 are required. After enabling of the version control integration, everything else will be performed automatically by the plugin.

0
Comment actions Permalink

On a mac and seem to be doing everything right but my workspaces never show up in Version Control / Azure Dev Ops Services / TFS ?

 

 

 

0
Comment actions Permalink

Mike Calvin, hello! Please note this is an article about importing of existing workspaces on Windows. If you have any other problems on macOS, then, please, submit a separate request or report your issue directly into the issue tracker.

1
Comment actions Permalink

Ivan,

OK Great, then where do I find instructions for Mac ? 

0
Comment actions Permalink

There're no instructions to import Visual Studio workspaces on Mac, because there're no workspaces created by Visual Studio on Mac. According to my knowledge, VS for Mac doesn't support the TFVC. So, you cannot import them, since there's nothing to import.

0
Comment actions Permalink

I am running evaluation copy of Rider 2020. The existing project is under Azure DevOps TFS  VCS system (not Azure DevOps git). There are many branches in the project. I am trying to figure out to checkout only specific branches and do regular works like send "Request review", "Review other devs code", "Commit" etc. Merging code from one branch to another is also important part of the code flow. Can you please help with this?

Edited by Vkumar2089
0
Comment actions Permalink

Hello,

I am trying to use my existing VS workspace with rider 2020. When I run the command tf.cmd workspaces command It will open tfs login window, after entering the username and password it shows below error

An error occurred: You do not have permission to access the server.

TF31003: Either you have not entered the necessary credentials or your user account does not have permission to connect to the Team Foundation Server at https://tfs.app.visualstudio.com/. Ask your server administrator to add the appropriate permissions to your account.

TF400813: The user 'Windows Live ID\xxxxxxxx' is not authorized to access this resource.

I checked  I have all the access on TFS server and username and password are correct and working, so why it showing Authorization error ? Can anyone please help me to solve the problem ?

Thanks!

0
Comment actions Permalink

Hello Namit Shah116,

To investigate this issue deeper please collect idea.log file after reproducing this behaviour once again (to find this file use menu "Help | Diagnostic Tools | Show Log in ..."). Then please attach it to the issue on Rider tracker I've just created according to your description: https://youtrack.jetbrains.com/issue/RIDER-49848.
Also, it would be great if you could make the following experiment:

- create a new organization on visualstudio.com https://docs.microsoft.com/en-us/azure/devops/organizations/accounts/create-organization?view=azure-devops
If a new organization is created on azure.com, please turn off the setting "Use the new URL" in "Organization settings":

- then try running the command "tf.cmd workspaces" for this created workspace

- let us know about the results (if the issue persists)

Kind regards,

Sofia.

0

Please sign in to leave a comment.

Have more questions?

Submit a request