title: Retrieve integers from a text file using PowerShell
body: <p>I would like to retrieve some numbers from a text file using Windows PowerShell. Assume that I have a text file <code>values.txt</code> that looks like this (I can modify it as I want):</p>
  
  <pre><code>foo=100
  bar=-3
  foobar=-15
  asdf=-4
  </code></pre>
  
  <p>I would like to add a variable to my PowerShell script called <code>$bar</code> that is equal to the number <code>-3</code>, as the text file says it should be. How do I do this?</p>