Reputation: 19684
I am new to working with the TFS API. Is there a way to query the VersionControlServer to get a list of folders an/or files given a path??
$/TeamProject/release/
Can I somehow get a collection of folders give this path?
Thanks
Upvotes: 1
Views: 1357
Reputation: 5003
You can use this code:
var allItems = sc.GetItems("$/TeamProject/release/*");
var folders = allItems.Items.Where(t => t.ItemType == ItemType.Folder);
var folderPaths = folders.Select(f => f.ServerItem);
Upvotes: 3