title: Setting environment variables package.json in Windows 10
body: <p><strong><em>UPDATE</strong>: As it is explained in the question, this is not a duplicate because I have already tried adding the <strong>set</strong> keyword before the environment variable and that did not solve the problem.</em></p>
  
  <hr>
  
  <p>I am in the process of learning node and typing examples from a book. The first examples deal with showing how the "http" module works and how to create a server to listen to requests. At some point the book asks to add the following line to the scripts section of the package.json file:</p>
  
  <blockquote>
    <p>"server": "SERVERPORT=3002 node ./fiboserver"</p>
  </blockquote>
  
  <p>When I try to run the example with <strong>npm run server</strong> I get the following error message:</p>
  
  <blockquote>
    <p>'SERVERPORT' is not recognized as an internal or external command</p>
  </blockquote>
  
  <p>I haven't been able to find any answer on the internet, at most I found that I could try:</p>
  
  <blockquote>
    <p>"server": "set SERVERPORT=3002 node ./fiboserver"</p>
  </blockquote>
  
  <p>But that doesn't help either, the only difference is that instead of the error message I get the command prompt again so apparently the server is never run.</p>
  
  <p>I believe the author used a Linux machine, I am using a Windows 10 laptop. </p>
  
  <p>I am really committed to learn Node and my line of work is on Windows environments. I believe that setting environment variables on package.json is important so I could really use some help in figuring this out.</p>
  
  <p>Thank you.</p>