title: npm version in Azure DevOps pipeline
body: <p>I have a build pipeline in Azure DevOps which releases artifact via <code>npm pack</code> for later publishing into Artifacts Feed.</p>
  <p>I would like to set my major and minor version via GIT but patch version to tie with build number. E.g.</p>
  <pre><code>1.2.20201212.4
  </code></pre>
  <p>where 1 and 2 is major.minor version manually updated via GIT
  and 20201212.4 is a patch and revision number <a href="https://docs.microsoft.com/en-us/azure/devops/pipelines/process/run-number?view=azure-devops&amp;tabs=yaml" rel="nofollow noreferrer">set by build pipeline</a></p>
  <p>Could someone help me to figure out the required <code>npm version</code> command parameters to preserve minor.major version from source code and update only patch and revision part from $(Build.BuildNumber) variable?</p>