title: How can I use a default value if an environment variable isn't set for resource filtering in maven?
body: <p>I am using resource filtering to replace some ${values} in a property file.  </p>
  
  <p>e.g. the file contains
  PROPERTY=${VALUE}</p>
  
  <p>I want ${VALUE}  to be replaced with environment variable $VALUE which works well if $VALUE is set when the build runs. Awesome.  </p>
  
  <p>However, these env vars are only set in our official build environment (by Jenkins) and not in developer builds so the ${values} are left in the property file after filtering which can break stuff. I'd rather not require env vars in developer environments as that always leads to fragile dev builds and whiny devs. </p>
  
  <p><strong>How can I use the environment variable value if its set and use another default property value if the env var isn't set?</strong>  </p>
  
  <p>From my testing it works the other way around by default, in that properties set in the pom will override environment variables for the purpose of resource filtering.</p>
  
  <p>Thanks</p>