title: Setting environment variables in Erlang applications
body: <p>There's clearly something I don't understand about Erlang... well, among many things. </p>
  
  <p>I've set up an application under Rebar called cw.I start it up and everything runs fine.</p>
  
  <p>Now I want to create an environment variable so I can access the src directory. I've entered the following in cw.app.src:</p>
  
  <pre><code>{env, [{proj_root, "mypath/apps/cw"}]}
  </code></pre>
  
  <p>Compile, start with Rebar start.sh... everything works fine. </p>
  
  <p>Now the mystery. Yesterday when I did this, I got the correct path when I entered application:get_env(cw, proj_root) in the Erlang shell. But today I get undefined.</p>
  
  <p>What am I missing?</p>
  
  <p>Many thanks,</p>
  
  <p>LRP</p>