【发布时间】:2014-10-16 18:49:01
【问题描述】:
我正在尝试使用 Powershell 连接到 VSO。这是我的代码:
$tfsServer = New-Object System.Uri("the server is here")
$creds = [System.Net.CredentialCache]::DefaultNetworkCredentials
$tfsCollection = New-Object Microsoft.TeamFoundation.Client.TfsTeamProjectCollection($tfsServer,$creds)
$tfsCollection.Authenticate()
当它到达 Authenticate 行时,它会弹出一个框让我输入我的凭据。我需要它不要弹出这个框,因为这个脚本将被安排,我不能继续输入凭据。如何将当前用户的凭据传递给 TFS 对象?
【问题讨论】:
标签: powershell authentication tfs azure-devops