0

我尝试与 tfs 服务器建立一些连接。我必须在调度程序中运行它,所以我需要提供用户名和密码。

如你看到的。我们使用 tfspreview 版本。使用用户名(LIVE ID mailadres)和密码。

当我删除密码时。有用。缓存中的用户名和密码?我删除了本地应用数据中的缓存!

当我们尝试使用密码时。我们得到以下错误。

    TF30064: You are not authorized to access the server.

我们使用的代码。

            REM @echo off
            REM ... Change the path below. This is the path where the code will be downloaded!
            REM Z:
            REM cd Backup_TFS_Preview
            REM call %VS100COMNTOOLS%\..\..\VC\vcvarsall.bat x86

            REM ... Navigate to folder
            Z:
            cd Backup_TFS_Preview

            REM ... Makes folder with date today
            mkdir %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4%

            REM ... Navigate to folder
            cd %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4%

            REM ... Add workspace for the folder with date of today
            "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\tf" workspace /login:username(LiveID mail adres),password /new /server:https://*.tfspreview.com/DefaultCollection %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4% /noprompt 

            REM ... Get all items from TFS
            "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\tf" get /recursive /all /noprompt

            REM ... Navigate to folder
            cd ..

            REM ... Zip the folder
            C:\TFS_Backup_Scripts\7z.exe a %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4%.zip %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4%\

            REM ... Remove folder
            rmdir %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4%\ /s /q

            REM ... Delete workspace
            "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\tf" workspace /delete %Date:~-10,2%-%Date:~-7,2%-%Date:~-4,4% /noprompt

            REM ... Navigate to folder
            cd ..
            cd ..

            REM ... Delete zip files that are older then 10 days 
            forfiles -p "Z:\Backup_TFS_Preview" -s -m *.* -d -10 -c "cmd /c del /q @path"

            PAUSE
4

1 回答 1

0

看起来您正在尝试从 Visual Studio 2010 的 TF.EXE 命令连接到 tfspreview,对吗?

即使您安装了 QFE 以在 Visual Studio 中启用 TFSPreview 访问,请注意这主要是一个“受限补丁”,并且 TF.EXE 并不完全符合 TFSPreview。

你应该安装 VS11 beta 并使用这个版本的 TF.EXE,也许你会更幸运。

顺便说一句,我看到您决心创建一个计划作业来备份 TFSPreview 源。您必须知道,即使平台处于预览状态,您的整个团队项目集合也将在 TFSPreview 获得 RTM 后保留 3 个月,并且您将多次收到以下可能性的通知:

  1. 升级到“付费版”
  2. 在从 MS 服务器销毁之前,在本地检索团队项目集合。

来自 MS 的 Brian Keller 对此非常清楚。所以不要害怕丢失你的代码。

更新: 来自 Brian Harry(TFS 大老板之一)的评论:

Brian Harry MS 2012 年 3 月 27 日下午 1:06 话虽如此,让我重复我之前说过的几件事:

1) 我们的目标是在类似功能的市场上具有成本竞争力。

2) 前几天我在 CodePlex 帖子中提到,我们设想跨 TFSPreview/CodePlex 提供统一服务,从免费扩展到付费 - 细节仍有待确定。

3)在我们建立任何计费模型之前,如果您认为这样更经济,我们将提供一种高保真且简单的方式将您的数据从云迁移到本地 TFS 服务器

随时在他的博客上联系 Brian 要求他确认,他总是回答人们。

于 2012-04-24T11:25:21.983 回答