title: How to replace string template (Gradle)
body: <p>I'm migrating from Maven to Gradle 4.4. There was several maven profiles with such sections:</p>
  
  <pre><code>&lt;properties&gt;
     &lt;module.suffix&gt;-14&lt;/module.suffix&gt;
     &lt;wildfly.hostname&gt;10.***.***.14&lt;/wildfly.hostname&gt;
  &lt;/properties&gt;
  </code></pre>
  
  <p>There are a lot of <code>${module.suffix}</code> in several resource files such as <code>.xml</code>, <code>.properties</code> and etc. I was able to run <code>mvn wildfly:deploy -Pdeploy-14</code> and got my <code>war</code> deployed with correct suffixes in all files. <strong>The problem is: how to do the same in Gradle?</strong> I'm new to Gradle but I believe it is modern powerful tool, it must be able to do this with ease.
  Help, please.</p>
  
  <p>P.S. The next step of my migration will be setting up the Gradle Wildfly plugin. I didnt try it yet, so if you have any useful advices please welcome.</p>
  
  <p><a href="https://stackoverflow.com/questions/33464577/gradle-task-replace-string-in-java-file">Gradle task replace string in .java file</a> didn't help (I tried all of the answers, but not sure I did it right).</p>
  
  <p><strong>UPD.</strong> When I try do to this</p>
  
  <pre><code>processResources {
      def params = [moduleSuffix: 'moduleSuffix']
      from 'src/template/resources', {
          expand params
      }
  }
  </code></pre>
  
  <p>the <code>expand</code> word is underlined and IDEA says "Cant resolve symbol 'expand'"</p>