Plugin Documentation

Goals available for this plugin:

GoalReport?Description
php:execNoexecutes a php command.
php:pharNopack a phar file using the contents of the library.
php:phpdocumentorYesA maven 2.0 plugin for generating phpdocumentor documentations. This plugin is used in the site phase.
php:phpunit-coverageYesA maven 2.0 plugin for generating phpunit code coverage reports. This plugin is used in the site phase.
php:resourcesNophp-validate execute the php with all php files under the source folder. All dependencies will be part of the include_path. The command line call looks like php {compileArgs} -d={generatedIncludePath} {sourceFile}
php:set-sourcesNoSets the source folders to php-maven sepcification (src/main/php and src/test/php). XXX: This seems to be a very bad hack. It copies some stuff from DefaultProjectBuilder in order to analyze the poms itself without having the parent poms influence them. This seems to be the only way to detect if the source folders are inherited from super pom or if they are explicitly set in the projects pom or one of its parent.
php:testNoPHPUnit executes phpunit TestCases and generate SourceFire Reports.
php:testResourcesNophp-validate execute the php with all php files under the source folder. All dependencies will be part of the include_path. The command line call looks like php {compileArgs} -d={generatedIncludePath} {sourceFile}

System Requirements

The following specifies the minimum requirements to run this Maven plugin:

Maven2.0
JDK1.6
MemoryNo minimum requirement.
Disk SpaceNo minimum requirement.

Usage

You should specify the version in your project's plugin configuration:

<project>
  ...
  <build>
    <!-- To define the plugin version in your parent POM -->
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.phpmaven</groupId>
          <artifactId>maven-php-plugin</artifactId>
          <version>2.0-SNAPSHOT</version>
        </plugin>
        ...
      </plugins>
    </pluginManagement>
    <!-- To use the plugin goals in your POM or parent POM -->
    <plugins>
      <plugin>
        <groupId>org.phpmaven</groupId>
        <artifactId>maven-php-plugin</artifactId>
        <version>2.0-SNAPSHOT</version>
      </plugin>
      ...
    </plugins>
  </build>
  ...
  <!-- To use the report goals in your POM or parent POM -->
  <reporting>
    <plugins>
      <plugin>
        <groupId>org.phpmaven</groupId>
        <artifactId>maven-php-plugin</artifactId>
        <version>2.0-SNAPSHOT</version>
      </plugin>
      ...
    </plugins>
  </reporting>
  ...
</project>

For more information, see "Guide to Configuring Plug-ins"