Skip to content
sample scripts for customers who are exporting and importing process templates to/from TFS
HTML PowerShell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
Export Add VS2019 Support and Ignore Exported Templates Aug 7, 2019
Import Add VS2019 edition paths to conform script Sep 19, 2019
GetProjects.ps1 modified scripts and readme to better reflect tfs on-prem Jul 18, 2016
License.txt Added MSFT License File Feb 18, 2016 updated readme Oct 30, 2017

Process Customization Scripts

These scripts are designed to automate the exporting and importing of your TFS process templates.


If you are using these script to help you with TFS Data Import, we suggest you use the tfsMigrator validate .. /saveprocesses command to export your processes.


tfsMigrator validate "http://myServer/tfs/DefaultCollection" /saveprocesses

The ExportProjectsTemplate.ps1 will connect to your TFS or VSTS project and extract the process template.

Folder Structure

Root Folder --- Default_EmptyTemplate --- Exported Templates --- ExportProjectTemplate.ps1


The folder contains series of files and folders that are needed when extracting the process template from the project. Don't change anything in this folder.


This is where your process template will be stored after the script run is completed. The PowerShell script specifically looks for this folder.


PowerShell script that extracts the process from the project and saves it into the ExportedTemplates folder


./ExportProjectTemplate.ps1 "collection" "projectname" -true


.\ExportProjectTemplate.ps1 "http://myServer/tfs/DefaultCollection" "foo" -force

Note: You will need to run the ExportProjectTemplate.ps1 script for each project


ConformProject.ps1 will take a defined process template that is on your local machine and apply it, in full, to a specified project. Typical use case for this is to update to the most recent OOB Agile, Scrum, or CMMI template. You may also be a large organization that has made a change to process and need to apply it many projects within your collection.

Process Template (Agile, Scrum, Customized)

You will need the entire process template downloaded in a location you can get access it via your desktop. When executing the script you supply the full path to this folder


PowerShell script that runs a takes a process template path and runs a series of witadmin commands to apply it to a supplied project.


./ConformProject.ps1 "collection" "projectname" "templatepath"


./ConformProject.ps1 "http://myServer/tfs/DefaultCollection" "foo" "c:\folder\agile"


use getprojects.ps1 to get a list or projects from a collection using the REST API's. You can also get the full list of projects from your TFS collection database by using the following sql:

Select * from tbl_projects where State = 'WellFormed' and PartitionId > 0


Contact with questions or issues

You can’t perform that action at this time.