Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <properties>
- <main.basedir>${project.parent.basedir}</main.basedir>
- ...
- </properties>
- <plugins>
- <plugin>
- <artifactId>maven-antrun-plugin</artifactId>
- <executions>
- <execution>
- <id>render-parameter-sql</id>
- <phase>validate</phase>
- <goals>
- <goal>run</goal>
- </goals>
- <configuration>
- <tasks>
- <echoproperties/>
- </tasks>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- main:
- [echoproperties] #Ant properties
- [echoproperties] #Thu Oct 28 09:32:13 CEST 2010
- [echoproperties] ant.core.lib=C:\Users\gaborl\.m2\repository\org\apache\ant\ant\1.8.1\ant-1.8.1.jar
- ...
- [echoproperties] main.basedir=${project.parent.basedir}
- [echoproperties] maven.dependency.antlr.antlr.jar.path=C:\Users\gaborl\.m2\repository\antlr\antlr\2.7.6\antlr-2.7.6.jar
- <plugin>
- <groupId>org.codehaus.gmaven</groupId>
- <artifactId>gmaven-plugin</artifactId>
- <version>1.3</version>
- <executions>
- <execution>
- <id>set-custom-property</id>
- <phase>validate</phase>
- <goals>
- <goal>execute</goal>
- </goals>
- <configuration>
- <source>
- project.properties.setProperty('main.basedir', project.parent.basedir.toString())
- </source>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <artifactId>maven-antrun-plugin</artifactId>
- <version>1.6</version>
- <executions>
- <execution>
- <id>render-parameter-sql</id>
- <phase>validate</phase>
- <goals>
- <goal>run</goal>
- </goals>
- <configuration>
- <target>
- <echo>project.artifactId : ${project.artifactId}</echo>
- <echo>project.parent.basedir : ${project.parent.basedir}</echo>
- <echo>main.basedir : ${main.basedir}</echo>
- <echo>project.basedir : ${project.basedir}</echo>
- <echo>project.build.directory : ${project.build.directory}</echo>
- </target>
- </configuration>
- </execution>
- </executions>
- </plugin>
Advertisement
Add Comment
Please, Sign In to add comment