title: shell script unable to set environment variable with the grepped value
body: <p>In the shell script, I want to grep a value from the log file and set as the value of one environment. In the log file, there is one line like this:</p>
  
  <pre><code>SOME_PATH=/some/specific/path
  </code></pre>
  
  <p>In my shell script, I grep the <code>SOME_PATH</code> keyword, and I got the above line and split it with <code>=</code>, but I'm now able to set the environment variable:</p>
  
  <pre><code>line=`grep "SOME_PATH" /path/to/the/log.log`
  path=${line##*=} 
  export SOME_PATH="$path"  #I cannot change the environment variable with this line.
  </code></pre>
  
  <p>And if I just have the script like below, the environment variable changes.</p>
  
  <pre><code>export SOME_PATH=/some/specific/path
  </code></pre>