<p>Visual Studio Team Services has a <a href="https://docs.microsoft.com/en-us/vsts/build-release/actions/build-yaml" rel="nofollow noreferrer">YAML Build</a> feature in public preview that allows you to store your build definitions as source controlled files.</p>

CC BY-SA 3.0
2017-12-11T23:27:20.327Z
2017-12-11T23:27:20.327Z
Daniel Mann
<p>The strict answer is no, in that there is no direct equivalent to a <a href="https://jenkins.io/doc/book/pipeline/jenkinsfile/" rel="nofollow noreferrer"><code>Jenkinsfile</code></a>. However, there are <a href="https://www.visualstudio.com/en-us/docs/work/customize/update-customized-process-template" rel="nofollow noreferrer">Build Process Templates</a> and you can use the <a href="https://github.com/psake/psake" rel="nofollow noreferrer">Psake Build Automation</a> tool in combination with templates to reduce the barriers to entry for creating a new build, test and deployment build definitions.</p>

<p>It is nowhere near as fluid as <a href="https://jenkins.io/doc/book/pipeline/jenkinsfile/" rel="nofollow noreferrer">Jenkins' Pipelines as Code</a>, <a href="https://www.google.co.uk/search?q=appveyor.yml&amp;rlz=1C1CHBF_en-GBGB714GB714&amp;oq=appveyor.yml&amp;aqs=chrome.0.0l6.2689j0j1&amp;sourceid=chrome&amp;ie=UTF-8" rel="nofollow noreferrer">AppVeyor's <code>appveyor.yml</code></a>, <a href="https://circleci.com/docs/1.0/configuration/" rel="nofollow noreferrer">CircleCI's <code>circleci.yml</code></a> and <a href="https://circleci.com/docs/1.0/configuration/" rel="nofollow noreferrer">Travis' <code>.travis.yml</code></a>.  There is a wealth of information on the <a href="https://blogs.msdn.microsoft.com/visualstudioalmrangers/2015/04/22/library-of-tooling-and-guidance-solutions-aka-msvsarsolutions/" rel="nofollow noreferrer">ALM Rangers Library of tooling and guidance solutions.</a></p>

CC BY-SA 3.0
2017-04-12T16:14:18.883Z
2017-04-12T16:14:18.883Z
Richard Slater
<p>I've seen some custom settings files used in combination with TFS build, but nothing native.  Does Team Foundation Server or Visual Studio Team Services have a Jenkinsfile-like, declarative method for defining a build process?</p>

CC BY-SA 3.0
2017-04-12T15:33:40.063Z
Do you have any specific requirements for TFS Build? That would probably help any answer to actually help you solve your problem—what I think is like a Jenkinsfile might be different to what you're expecting, so a few constraints would be useful to know.
Aurora0001
CC BY-SA 3.0
2017-04-12T17:19:09.250Z
I'm generally looking to provide the ability to source-control the build process, in the same way that a Jenkinsfile does.  TFS build pipelines are very opinionated, and fine-grained access to them doesn't look possible.
Dave Swersky
<jenkins><tfs><jenkinsfile>
Does TFS Build have something like a Jenkinsfile?
Dave Swersky
# Does TFS Build have something like a Jenkinsfile?

(Asked by: username_0 on 2017-04-12)

I've seen some custom settings files used in combination with TFS build, but nothing native. Does Team Foundation Server or Visual Studio Team Services have a Jenkinsfile-like, declarative method for defining a build process?

**Tags:** jenkins, tfs, jenkinsfile

> **Comments:**
> **username_1**: Do you have any specific requirements for TFS Build? That would probably help any answer to actually help you solve your problem—what I think is like a Jenkinsfile might be different to what you're expecting, so a few constraints would be useful to know.  
> **username_0**: I'm generally looking to provide the ability to source-control the build process, in the same way that a Jenkinsfile does.  TFS build pipelines are very opinionated, and fine-grained access to them doesn't look possible.  

---

## 2 answers

### Answer by username_3 on 2017-04-12. Score: 4 | Accepted answer

The strict answer is no, in that there is no direct equivalent to a [`Jenkinsfile`](https://jenkins.io/doc/book/pipeline/jenkinsfile/). However, there are [Build Process Templates](https://www.visualstudio.com/en-us/docs/work/customize/update-customized-process-template) and you can use the [Psake Build Automation](https://github.com/psake/psake) tool in combination with templates to reduce the barriers to entry for creating a new build, test and deployment build definitions.

It is nowhere near as fluid as [Jenkins' Pipelines as Code](https://jenkins.io/doc/book/pipeline/jenkinsfile/), [AppVeyor's `appveyor.yml`](https://www.google.co.uk/search?q=appveyor.yml&rlz=1C1CHBF_en-GBGB714GB714&oq=appveyor.yml&aqs=chrome.0.0l6.2689j0j1&sourceid=chrome&ie=UTF-8), [CircleCI's `circleci.yml`](https://circleci.com/docs/1.0/configuration/) and [Travis' `.travis.yml`](https://circleci.com/docs/1.0/configuration/). There is a wealth of information on the [ALM Rangers Library of tooling and guidance solutions.](https://blogs.msdn.microsoft.com/visualstudioalmrangers/2015/04/22/library-of-tooling-and-guidance-solutions-aka-msvsarsolutions/)


---

### Answer by username_2 on 2017-12-11. Score: 4

Visual Studio Team Services has a [YAML Build](https://docs.microsoft.com/en-us/vsts/build-release/actions/build-yaml) feature in public preview that allows you to store your build definitions as source controlled files.


---

