CleanCode logo
sitemap
SEARCH:

CleanCode PowerShell Libraries v1.2.08 API: CleanCode » TfsTools » Get-StaleTfsFiles

Get-StaleTfsFiles

NAME

Get-StaleTfsFiles

SYNOPSIS

Retrieves a list of files where one or more files are not current with the TFS repository.

SYNTAX

Get-StaleTfsFiles [[-Path] <String>] [<CommonParameters>]

DESCRIPTION

Returns details about files and folders that are not current with the TFS repository (see example). As such, the IsLatest property will always show *False*. Other properties indicate:
* whether the item is completely new (IsInWorkspace will be False and VersionLocal will be 0).
* whether the item is simply out-of-date (VersionLatest will be larger than VersionLocal).
* whether you have edited the local item (ChangeType will be Edit rather than None).

Refer to Get-TfsDetails to see the same information on all files (current or not). Refer to Get-StaleTfsFolders or Get-StaleTfsProjects to see a summary of stale files.

PARAMETERS

-Path <String>
        The root of the subtree to check.
        If omitted, uses the current directory.

        Required?                    false
        Position?                    1
        Default value                .
        Accept pipeline input?       false
        Accept wildcard characters?  false

<CommonParameters>
        This cmdlet supports the common parameters: Verbose, Debug,
        ErrorAction, ErrorVariable, WarningAction, WarningVariable,
        OutBuffer and OutVariable. For more information, see 
        about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 

INPUTS

None. You cannot pipe objects to Get-StaleTfsFiles.

OUTPUTS

Array of PSCustomObjects (similar to Microsoft.TeamFoundation.VersionControl.Client.ExtendedItem).

NOTES



        This function is part of the CleanCode toolbox
        from http://cleancode.sourceforge.net/.

        Since CleanCode 1.2.06.

EXAMPLES


-------------------------- EXAMPLE 1 --------------------------

PS>cd Project; Get-StaleTfsFiles | Format-Table -AutoSize

Tabular output will typically look better by piping to Format-Table as shown.

        Name                IsInWorkspace IsLatest ChangeType IsBranch VersionLatest VersionLocal
        ----                ------------- -------- ---------- -------- ------------- ------------
        Some.Folder                 False    False       None    False         18275            0
        Some.Other.Folder           False    False       None    False         18102            0
        NetworkAdmin.csproj          True    False       None    False         18097         2177
        AssemblyInfo.cs              True    False       None    False         18097         1879
        ConnectionDialog.cs          True    False       None    False         18097         1879

-------------------------- EXAMPLE 2 --------------------------

PS>Get-StaleTfsFiles | Select Name, Project, Folder

Depending on your window width you may not see all the object properties with Format-Table. Pipe to Select-Object to see specific properties as shown here.

        Name                Project      Folder
        ----                -------      ------
        Some.Folder         Main         .\MyRoot.DevCore\src\Main\Infrastructure
        Some.Other.Folder   ??           .\MyRoot.DevCore\src
        NetworkAdmin.csproj NetworkAdmin .\MyRoot.DevCore\src\NetworkAdmin
        AssemblyInfo.cs     NetworkAdmin .\MyRoot.DevCore\src\NetworkAdmin\Properties
        ConnectionDialog.cs NetworkAdmin .\MyRoot.DevCore\src\NetworkAdmin\src

The '??' indicates that the file is above the level of project folders so there is no associated project. Note that you will also see an unknown marker for files that you have never downloaded into your workspace (i.e. new files introduced by someone else).

RELATED LINKS

This documentation set was created with CleanCode's DocTreeGenerator.

Valid XHTML 1.0!Valid CSS!Get CleanCode at SourceForge.net. Fast, secure and Free Open Source software downloads
Copyright © 2001-2015 Michael Sorens • Contact usPrivacy Policy
Usage governed by Mozilla Public License 1.1 and CleanCode Courtesy License
CleanCode -- The Website for Clean DesignRevised 2015.12.16