如何使用在 unix 上运行的 TFS 命令行客户端创建新的 Windows 工作区 [英] How do you create new windows workspace with TFS command line client that is running on unix

查看:36
本文介绍了如何使用在 unix 上运行的 TFS 命令行客户端创建新的 Windows 工作区的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将如何使用在 aix/unix 机器上运行的 TFS 命令行客户端来运行 tf 命令.例如,我无法创建连接到 Windows 服务器上的 tfs 版本控制文件夹的本地 Windows 工作区.在 unix box 上运行的命令行客户端的版本是 (/TFS/TEE-CLC-12.0.0).我找不到任何文档,说明在 unix 上运行时如何使用客户端将本地 Windows 文件连接到服务器上的版本控制文件.

How would I work with the TFS command line client that is running on a aix/unix box to run the tf commands. For example I'm unable to create local windows workspaces that connect to the tfs version control folders that are on a windows server. The version of command line client that is running on the unix box is (/TFS/TEE-CLC-12.0.0). I can't find any documentation how the client can be used when running on unix to connect local windows files to the version control files on a server.

推荐答案

在任何平台上从服务器获取源文件都需要三个步骤:

Getting source files down from the server requires three steps on any platform:

  1. 在您的服务器上创建一个工作区.工作区包含有关服务器上所需文件和本地文件的元数据.

  1. Create a workspace on your server. A workspace is what contains the metadata about the files you want on the server and the files you have locally.

(从技术上讲,您不在服务器上创建工作区,而是在团队项目集合上创建,这是服务器中的一个逻辑单元;默认情况下您的服务器上有一个名为DefaultCollection"的团队项目集合.)

(Technically, you don't create a workspace on the server, you do it on a Team Project Collection which is a logical unit in the server; by default you have a single Team Project Collection on your server called - uncreatively - "DefaultCollection".)

创建一个或多个工作文件夹映射,以指示您要获取的服务器文件路径以及将它们放置在本地磁盘上的位置.对于不复杂的项目,这就像将 $/Project/Folder 映射到 C:\Project\Folder/project/folder 一样简单.

Create one or more working folder mappings that indicate the server's file paths you want to get, and where to put them on your local disk. For an uncomplicated project, this is as simple as mapping $/Project/Folder to C:\Project\Folder or /project/folder.

执行get,从服务器下载文件,将它们放在您在步骤 2 中配置的本地文件夹中.

Do a get, to download the files from the server, placing them in the local folders you configured in step 2.

例如,我有一个跨平台项目,它恰好是 Team Explorer Everywhere 本身.在这种情况下,我的服务器是 https://tee.visualstudio.com/DefaultCollection.我的源代码位于 $/TEE/Main 的服务器上.我想将它放在我的 AIX 框上的是 /build/tee/main.

For example, I have a cross-platform project which happens to be Team Explorer Everywhere itself. In this case my server is https://tee.visualstudio.com/DefaultCollection. My source is located on the server at $/TEE/Main. And I want to place it on my AIX box is /build/tee/main.

服务器和服务器文件夹都没有改变,因为我不在 Windows 上.唯一改变的是 - 不出所料 - 本地路径.我将在我的 AIX 5.2 机器上完成这些步骤:

Neither the server nor the server folder change because I'm not on Windows. The only thing that changes is - unsurprisingly - the local path. I'll walk through these steps on my AIX 5.2 box:

  1. 创建工作区:

  1. Create a workspace:

ethomson@aix:~% tf workspace -new MyWorkspace -collection:https://tee.visualstudio.com/DefaultCollection
Workspace 'MyWorkspace' created.

  • 创建一个从 $/TEE/Main/build/tee/main 的工作文件夹映射:

  • Create a working folder mapping from $/TEE/Main to /build/tee/main:

    ethomson@aix:~% tf workfold -map '$/TEE/Main' /build/tee/main -collection:https://tee.visualstudio.com/DefaultCollection -workspace:MyWorkspace 
    

  • 获取文件.(既然已经配置了工作文件夹映射,则无需指定服务器 URL 或工作区名称,只要指定本地路径即可.)

  • Get the files. (Now that you have configured a working folder mapping, you do not need to specify the server URL or the workspace name as long as you specify the local path.)

    ethomson@aix:~% cd /build/tee/main
    ethomson@aix:/build/tee/main% tf get -recursive .
    /build/tee:
    Getting main
    
    /build/tee/main:
    Getting build
    
    /build/tee/main/build:
    Getting .project
    Getting .settings
    ...etc...
    

  • 这篇关于如何使用在 unix 上运行的 TFS 命令行客户端创建新的 Windows 工作区的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

    查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆