title: Make Maven child poms have same version number as parent?
body: <p>I have a multi-module (aggregator) Maven project that also inherits properties from the parent pom.   So in my parent pom.xml I have this:</p>
  
  <pre><code>&lt;groupId&gt;com.something.project&lt;/groupId&gt;
  &lt;artifactId&gt;MyProject&lt;/artifactId&gt;
  &lt;packaging&gt;pom&lt;/packaging&gt;
  &lt;version&gt;1.0.123&lt;/version&gt;
  
  &lt;modules&gt;
      &lt;module&gt;ModuleA&lt;/module&gt;
      &lt;module&gt;ModuleB&lt;/module&gt;
      &lt;module&gt;ModuleC&lt;/module&gt;
  &lt;/modules&gt;
  </code></pre>
  
  <p>I would like to have all the child modules inherit the parent version number <code>1.0.123</code>, but the child <code>pom.xml</code> requires me to go ahead and hardcode the version number of the parent anyway (ModuleA pom.xml example):</p>
  
  <pre><code>&lt;artifactId&gt;ModuleA&lt;/artifactId&gt;
  &lt;name&gt;Some Amazing Thing&lt;/name&gt;
  
  &lt;parent&gt;
      &lt;relativePath&gt;../&lt;/relativePath&gt;
      &lt;artifactId&gt;MyProject&lt;/artifactId&gt;
      &lt;version&gt;1.0.123&lt;/version&gt;
      &lt;groupId&gt;com.something.project&lt;/groupId&gt;
  &lt;/parent&gt;
  </code></pre>
  
  <p>How can I just put the version number in the parent pom, and have the modules inherit it without having to update it in multiple places?   So far I've tried ${project.version} and ${project.parent.version} and Maven seems very unhappy with that.   Nor can I remove the version reference entirely.   </p>
  
  <p>Does anyone have a good answer for this?</p>