{"id":21032486,"url":"https://github.com/majkinetor/tfs","last_synced_at":"2025-05-15T13:31:10.035Z","repository":{"id":76787029,"uuid":"56223204","full_name":"majkinetor/TFS","owner":"majkinetor","description":" Powershell module to drive TFS 2015+ via REST interface","archived":true,"fork":false,"pushed_at":"2018-09-28T15:21:04.000Z","size":48,"stargazers_count":16,"open_issues_count":2,"forks_count":6,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-05-13T12:05:17.264Z","etag":null,"topics":["continuous-integration","powershell","powershell-module","tfs"],"latest_commit_sha":null,"homepage":"","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/majkinetor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"license.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-04-14T09:09:03.000Z","updated_at":"2024-12-31T17:59:16.000Z","dependencies_parsed_at":null,"dependency_job_id":"ccb43a8d-7d69-4dac-9347-84aac6ad4b89","html_url":"https://github.com/majkinetor/TFS","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/majkinetor%2FTFS","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/majkinetor%2FTFS/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/majkinetor%2FTFS/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/majkinetor%2FTFS/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/majkinetor","download_url":"https://codeload.github.com/majkinetor/TFS/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254349275,"owners_count":22056312,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["continuous-integration","powershell","powershell-module","tfs"],"created_at":"2024-11-19T12:43:23.718Z","updated_at":"2025-05-15T13:31:10.023Z","avatar_url":"https://github.com/majkinetor.png","language":"PowerShell","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![](https://img.shields.io/badge/PowerShell%20Gallery-TFS-blue.svg)](https://www.powershellgallery.com/packages/tfs)\n\nTFS\n===\n\nThis is Powershell module to communicate with [Team Foundation Server](https://www.visualstudio.com/en-us/products/tfs-overview-vs.aspx) 2015 via its [REST interface](https://www.visualstudio.com/integrate/get-started/rest/basics). It provides commands which allow you to create, update, export and import build definitions, get build logs, projects, repositories etc. The goal of the module is to be able to automate TFS setup and put its configuration on the project repository.\n\nThe module is tested with Team Foundation Server Update 2.\n\nInstallation\n============\n\nOn Windows 10 or Powershell 5+ use: `Install-Module TFS`. \n\nTo install manually, copy the module to the one of the directories listed in `$Env:PSModulePath`.\n\nConfiguration\n=============\n\nModule uses global variable `$tfs` for its configuration:\n\n    $global:tfs = @{\n        root_url    = 'http://tfs015:8080/tfs'\n        collection  = 'DefaultCollection'\n        project     = 'ProjectXYZ'\n    }\n\nSome attributes will take defaults if you don't specify them:\n\n    $tfs.collection  = 'DefaultCollection'\n    $tfs.api_version = '2.0'\n\nIf you need to work constantly on a single project put this setting in your `$PROFILE`. To manage multiple projects or collections or TFS servers you could create multiple functions for each scenario that each set `$global:tfs` in its own way, for example:\n\n    function set_tfs_test() {\n        $global:tfs = @{ ... }\n    }\n\nThen, prior to calling any module function run `set_tfs_test`.\n\nTFS Credentials\n---------------\n\nModule keeps TFS credential in the `$tfs.Credentials`. If not specified you will be prompted for the credentials when running any of the functions. If the module [CredentialManager](https://github.com/davotronic5000/PowerShell_Credential_Manager) is available (to install it run `Install-Module CredentialManager` in Powreshell 5+) credentials will be stored in the Windows Credential Manager and after first run, you will be able to use any function in any PS session using your stored credentials.\n\nTo use _ad hoc_ credentials when you have your main credential stored simply use: \n    \n    $tfs.Credentials = Get-Credential\n\nThis way stored credentials will be overridden only for the current session. To change the stored credentials for all subsequent sessions either delete them using the Control Panel (Manage Windows Credentials) and run any function again or use the following command:\n\n    $tfs.Credentials = New-TFSCredential    #Get credential and store it in Credential Manager.\n\nUsage\n=====\n\n* To view all supported commands execute `gcm -m tfs` \n* To get all aliases execute `get-alias | ? source -eq 'tfs'`\n* Use `man` to get help for the command: `man builds -Example`\n\nAll functions have a `Verbose` parameter that shows very detailed log of every step involved:\n\n    PS\u003e Get-TFSBuildLogs -Verbose\n\n    VERBOSE: No credentials specified, trying Windows Credential Manager\n    VERBOSE: Populating RepositorySourceLocation property for module CredentialManager.\n    VERBOSE: Loading module from path 'C:\\Program Files\\WindowsPowerShell\\Modules\\CredentialManager\\1.0\\CredentialManager.dll'.\n    VERBOSE: Trying to get storred credentials for 'http://tfs015:8080/tfs'\n    VERBOSE: Retrieving requested credential from Windows Credential Manager\n    VERBOSE: New TFS credentials for 'http://tfs015:8080/tfs'\n    VERBOSE: TFS Credential: majkinetor\n    VERBOSE: URI: http://tfs015:8080/tfs/DefaultCollection/ProjectXYZ/_apis/build/builds?api-version=2.0\n    VERBOSE: received 793807-byte response of content type application/json; charset=utf-8; api-version=2.0\n    VERBOSE: Build id: 1456\n    VERBOSE: Logs URI: http://tfs015:8080/tfs/DefaultCollection/ProjectXYZ/_apis/build/builds/1456/logs?api-version=2.0\n    VERBOSE: GET http://10.1.6.27:8080/tfs/DefaultCollection/ProjectXYZ/_apis/build/builds/1456/logs?api-version=2.0 with 0-byte payload\n    VERBOSE: received 738-byte response of content type application/json; charset=utf-8; api-version=2.0\n    VERBOSE: Log URI: http://tfs015:8080/tfs/DefaultCollection/cc756267-fb53-4148-906f-471588d87bcb/_apis/build/builds/1456/logs/1\n    ...\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmajkinetor%2Ftfs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmajkinetor%2Ftfs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmajkinetor%2Ftfs/lists"}