title: How to use Git LFS with Azure Repos and Pipelines
body: <p>I have a project using Git LFS in Azure Repos with several binary image files being checked in using Git LFS. When my Azure Pipelines build performs a <code>git pull</code>, the image files are not pulled from Git LFS and I am left with several zero byte image files.</p>
  
  <p>I'm using a custom self-hosted Azure Pipelines build server which has a recent version of Git LFS installed on it:</p>
  
  <pre class="lang-bsh prettyprint-override"><code>PS C:\rehan&gt; git lfs --version                                                                                     git-lfs/2.7.2 (GitHub; windows amd64; go 1.12.2; git 08a08ae0)
  </code></pre>
  
  <p>I've tried adding steps to perform a <code>git lfs install</code> but that doesn't help. When I manually perform a <code>git lfs pull</code> after logging on to the build server, the files are downloaded correctly. When I run <code>git lfs pull</code> as a build step in my Azure Pipeline, I get the following error:</p>
  
  <pre><code>fatal: could not read Username for 'https://foo.visualstudio.com': terminal prompts disabled
  batch response: Git credentials for https://foo.visualstudio.com/Bar/_git/Bar not found.
  error: failed to fetch some objects from 'https://foo.visualstudio.com/Bar/_git/Bar.git/info/lfs'
  Downloading LFS objects:   0% (0/1), 0 B | 0 B/s                                
  ##[error]PowerShell exited with code '1'.
  </code></pre>