title: BASH - FOR loop using LS and wildcard
body: <p>My directory contains the following files:</p>
  <pre><code>FILE1_h0_something_1950_other.gz
  FILE2_h0_something_1950_other.gz
  FILE3_h0_something_1950_other.gz
  </code></pre>
  <p>Here a portion of my bash script:</p>
  <pre><code>year=1950
  for nc_gz in &quot;$input_path/*h3*$year*.gz&quot;; do
        gunzip $nc_gz
  done
  </code></pre>
  <p>I noted that SOMETIMES (strange behavior... I except always or never) a file named <strong><em>h3</em>1950</strong>* is created inside my dir.</p>
  <p>The code fails when directory contains no gz files.</p>
  <p>Where is the issue?</p>