【问题标题】:Get-TfsItemHistory not working TFS 2010Get-TfsItemHistory 不工作 TFS 2010
【发布时间】:2011-05-30 01:37:43
【问题描述】:

问题是执行以下命令没有返回任何内容。我知道有些项目的签入日期大于 2010 年 12 月 5 日。如果我将 -gt 更改为 -lt,我会按预期获得数千条记录,但 -gt 不起作用,我无法弄清楚正在发生的事情。我想要的是来自 TFS 的单个文件的不同列表,这些文件已经在 2010 年 12 月 5 日之后以 Edit 的状态签入,但我什至无法让 -gt 工作。想法?

在 Windows 7 x64 客户端上运行此命令。我安装了十月 TFS Powershell CmdLets。 TFS 2010 安装在 Windows 2008 服务器上。

Get-TfsItemHistory $/MyPath -recurse -all | where {  $_.CheckinDate -gt (Get-Date).AddDays(-17)}  | Select-TfsItem

【问题讨论】:

    标签: powershell tfs


    【解决方案1】:

    我不认为 CheckinDate 是你想在这里使用的。 Get-TfsItemHistory 返回变更集列表。 CheckinDate 在文件上。

    尝试使用 CreationDate:

    Get-TfsItemHistory $/MyPath -recurse -all | where {  $_.CreationDate -gt (Get-Date).AddDays(-17)}  | Select-TfsItem
    

    【讨论】:

      猜你喜欢
      • 2016-05-22
      • 2012-01-29
      • 2011-02-16
      • 2012-07-01
      • 2016-02-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多