SonarQube PHP
  1. SonarQube PHP
  2. SONARPHP-232

Update the plugin site with a simple "How To Use" section.

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.3
    • Fix Version/s: 0.4
    • Component/s: None
    • Labels:
      None
    • Number of attachments :
      0

      Description

      In order analyse a PHP project with Sonar, it is still required to a add a simple POM file into the project root.
      For PHP developers with no Maven experience it may be difficult to understand where to start. (Actually currently it's not really mentioned at all at the plugin site)

      It would be good to include a simple "How To Use It" like the following:

      How To Use It:

      • Make sure Apache Maven 2.2.1 is installed on the machine hosting the PHP project (see http://maven.apache.org/).
      • Create a POM file (pom.xml) inside the root directory of your project identifying your project within Sonar:
        <?xml version="1.0" encoding="UTF-8"?>
        <project xmlns="http://maven.apache.org/POM/4.0.0" 
                 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
                     http://maven.apache.org/xsd/maven-4.0.0.xsd">
        
          <modelVersion>4.0.0</modelVersion>
        
          <groupId>com.mycompany.projectGroupId</groupId>
          <artifactId>projectName</artifactId>
          <name>Human Readable Project Name</name>
          <version>1.0-SNAPSHOT</version>
        
          <description>
            Some more details on "Project Name"
          </description>
        
          <build>
            <outputDirectory>target</outputDirectory>
            <sourceDirectory>sources</sourceDirectory>
            <testSourceDirectory>tests</testSourceDirectory>
          </build>
        
          <properties>
            <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
            <sonar.language>php</sonar.language>
          </properties>
        </project>
          
      • Execute "mvn sonar:sonar" in the same path to analyse your project.

        Activity

        Show
        Akram Ben Aissi added a comment - http://docs.codehaus.org/display/SONAR/How+Sonar+PHP+Plugin+works

          People

          • Assignee:
            Akram Ben Aissi
            Reporter:
            Anonymous
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: