我需要能够通过 Powershell 更改 Team Foundation Server 2010 中文件的“ANSI NULL”属性:
cls
if ( (Get-PSSnapin -Name Microsoft.TeamFoundation.PowerShell -ErrorAction SilentlyContinue) -eq $null )
{
Add-PSSnapin Microsoft.TeamFoundation.PowerShell
}
[Microsoft.TeamFoundation.Client.TfsTeamProjectCollection] $tfs = get-tfsserver "http://tfsserver.com"
$items = Get-TfsItemProperty -Server $tfs -Item "$/databaseproject/Database/trunk/Database/Stored Procedures" -Recurse | where{$_.ItemType -eq "File"}
foreach($item in $items)
{
#i'm stuck on how to get/change the file item properties
}
本质上,我想将 TFS 中 .sql 文件的 ANSI NULLS 属性从 ON 更改为 OFF。我有大约 60 个要更改。
蒂亚!