IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Maven Java Discussion :

[MAVEN 2 & Eclipse] Génération du site


Sujet :

Maven Java

  1. #1
    Nouveau membre du Club
    Inscrit en
    Mai 2004
    Messages
    49
    Détails du profil
    Informations forums :
    Inscription : Mai 2004
    Messages : 49
    Points : 25
    Points
    25
    Par défaut [MAVEN 2 & Eclipse] Génération du site
    Hello les gens

    Je taffe sur un workflow à mettre en place avec Maven 2 sous Eclipse, et j'ai quelques soucis sur le pom, plus particulièrement sur la génération du site. Je lance mon m2 build sous Eclipse avec comme goal "site" et il me génère tout bien... sauf que je n'ai au final pas de "index.html" dans mon repertoire de sortie

    Comment se fait-ce, ai je envie de dire

  2. #2
    Membre confirmé

    Inscrit en
    Septembre 2006
    Messages
    466
    Détails du profil
    Informations forums :
    Inscription : Septembre 2006
    Messages : 466
    Points : 515
    Points
    515
    Par défaut
    Je pense que ton problème est indépendant d'Eclipse.
    As-tu essayer de mettre cela dans ta section reporting ?
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
     
      <reporting>
          <plugins>
    	   <plugin>
    	        <groupId>org.apache.maven.plugins</groupId>
    	        <artifactId>maven-project-info-reports-plugin</artifactId>
    	        <reportSets>
    	          <reportSet>
    	              <reports>
    	                <report>dependencies</report>
                            <report>dependency-convergence</report>
    	                <report>project-team</report>
                            <report>cim</report>
    	                <report>mailing-list</report>
    	                <report>issue-tracking</report>
    	                <report>license</report>
    	                <report>scm</report>
                            <report>index</report>
                            <report>summary</report>
    	              </reports>
    	          </reportSet>
    	       </reportSets>
    	     </plugin>
                 [...]
    Tu n'as qu'a choisir les reports qui t'intéressent mais il semble qu'il faille mettre <report>index</report> pour avoir le fichier index.html.

    Rémy

  3. #3
    Membre actif Avatar de dvicente72
    Profil pro
    Inscrit en
    Novembre 2004
    Messages
    213
    Détails du profil
    Informations personnelles :
    Âge : 52
    Localisation : France

    Informations forums :
    Inscription : Novembre 2004
    Messages : 213
    Points : 226
    Points
    226
    Par défaut Génération du site
    Comme le dit le précédent message :

    <reporting>
    <plugins>
    <plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>
    maven-project-info-reports-plugin
    </artifactId>
    </plugin>
    </reporting>

    ça suffit amplement mais le plus simple serait de nous donner ton POM si tu es en projet seul ou ta configuration de POM si tu es en multi-projets

  4. #4
    Nouveau membre du Club
    Inscrit en
    Mai 2004
    Messages
    49
    Détails du profil
    Informations forums :
    Inscription : Mai 2004
    Messages : 49
    Points : 25
    Points
    25
    Par défaut
    Dsl pour le retard ...

    Voici le pom

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    <?xml version="1.0"?>
    <project>
      	<modelVersion>4.0.0</modelVersion>
      	<groupId>camj</groupId>
      	<artifactId>CamjWorkflowRH</artifactId>
      	<version>1.0-SNAPSHOT</version>
      	<packaging>jar</packaging>
      	<name>WorkflowRH</name>
            <scm>[...]</scm>
     
    	<developers>[...]</developers>
     
    	<distributionManagement>[...]</distributionManagement>
     
        <build>
    		<defaultGoal>install</defaultGoal>  
    		<directory>${basedir}/target</directory>
    		<finalName>${artifactId}-${version}</finalName>
    		<sourceDirectory>${basedir}/trunk/src</sourceDirectory>
    		<outputDirectory>${basedir}/target/classes</outputDirectory>
    		<testSourceDirectory>${basedir}/trunk/src/test</testSourceDirectory>
    		<testOutputDirectory>${basedir}/target/test-classes</testOutputDirectory>
     
        	<plugins>
    	      	<plugin>
    	        	<groupId>org.apache.maven.plugins</groupId>
    	      	   	<artifactId>maven-compiler-plugin</artifactId>
    				<configuration>
    	        		<source>1.5</source>
    			        <target>1.5</target>
    	      		</configuration>
    	      	   	<executions>
    	      	   		<execution>
    	      				<phase>process-class</phase>
    	      				<goals>
    	      					<goal>compile</goal>
    	      				</goals>
    	      			</execution>
    	      	   </executions>
    			</plugin>
    	        <plugin>
    	        	<groupId>org.apache.maven.plugins</groupId>
    		   		<artifactId>maven-javadoc-plugin</artifactId>
    		   		<executions>
    		   			<execution>
    						<phase>process-class</phase>
    						<goals>
    							<goal>javadoc</goal>
    						</goals>
    					</execution>
    		   		</executions>
    			</plugin>
    			<plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>findbugs-maven-plugin</artifactId>
                    <configuration>
                        <threshold>Ignore</threshold>
                    </configuration>
                    <executions>
                        <execution>
                            <id>findbugs</id>
                            <phase>verify</phase>
                            <goals>
                                <goal>findbugs</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
    			<plugin>
    		    	<groupId>org.apache.maven.plugins</groupId>
    			   	<artifactId>maven-site-plugin</artifactId>
    				<configuration>
    	          		<locales>fr</locales>
    				</configuration>
    			   	<executions>
    			   		<execution>
    						<phase>process-class</phase>
    						<goals>
    							<goal>site</goal>
    						</goals>
    					</execution>
    			   	</executions>
    			</plugin>
    	   	</plugins>
      	</build>
     
    	<dependencies>
        	<dependency>
          		<groupId>junit</groupId>
          		<artifactId>junit</artifactId>
          		<version>3.8.1</version>
          		<scope>test</scope>
        	</dependency>
    	</dependencies>
     
        <reporting>
        	<plugins>
     
    <!-- *** GENERATION JAVADOC *** -->
        		<plugin>
    	            <groupId>org.apache.maven.plugins</groupId>
    	            <artifactId>maven-javadoc-plugin</artifactId>
    	            <reportSets>
    		            <reportSet>
    	    	            <id>html</id>
    	        		    <configuration>
    	                		<show>public</show>
    			            </configuration>
    	        	        <reports>
    	                    	<report>javadoc</report>
    	                  	</reports>
    	               	</reportSet>
    	            </reportSets>
             	</plugin>
     
    <!-- *** GENERATION CHECKSTYLE *** -->
            	<plugin>
              		<groupId>org.apache.maven.plugins</groupId>
              		<artifactId>maven-checkstyle-plugin</artifactId>
    	        </plugin>
     
    <!-- *** GENERATION FINDBUGS *** -->
    			<plugin>
    			    <groupId>org.codehaus.mojo</groupId>
    			    <artifactId>findbugs-maven-plugin</artifactId>
    			    <configuration>
    			    	<threshold>Normal</threshold> <!-- |Normal|Low|High|Exp|Ignore -->
    			      	<effort>Default</effort> <!-- Min|Default|Max -->
    			    </configuration>
    			</plugin>
     
    <!-- *** GENERATION DES RAPPORTS PAR DEFAUT *** -->
        	    <plugin>
    	    	    <groupId>org.apache.maven.plugins</groupId>
    	        	<artifactId>maven-project-info-reports-plugin</artifactId>
    				<reportSets>
    	          		<reportSet>
    	              		<reports>
    	                		<report>dependencies</report>
                            	<report>dependency-convergence</report>
    			                <report>project-team</report>
           			            <report>cim</report>
    	            		    <report>mailing-list</report>
    			                <report>issue-tracking</report>
    	   				        <report>license</report>
    	                		<report>scm</report>
    	                        <report>index</report>
        	                    <report>summary</report>
    	    	          </reports>
    	        	  	</reportSet>
    				</reportSets>	        	
    	        </plugin>
     
    <!-- *** GENERATION DES SOURCES NAVIGABLES EN HTML *** -->	        
    		   	<plugin>
    		    	<groupId>org.codehaus.mojo</groupId>
    		    	<artifactId>jxr-maven-plugin</artifactId>
    				<configuration>
    			        <linkJavadoc>true</linkJavadoc>
    		  			<javadocDir>${basedir}/target/site/apidocs</javadocDir>
    		        </configuration>		    	
    		   	</plugin>	        
          	</plugins>
      	</reporting>
    </project>
    Question : a quoi sert dans le pom de mettre le findbugs ET dans le build ET dans le reporting ?

  5. #5
    Membre actif Avatar de dvicente72
    Profil pro
    Inscrit en
    Novembre 2004
    Messages
    213
    Détails du profil
    Informations personnelles :
    Âge : 52
    Localisation : France

    Informations forums :
    Inscription : Novembre 2004
    Messages : 213
    Points : 226
    Points
    226
    Par défaut
    Salut,

    normalement , tu n'as pas besoin de plus que ça :

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
     
    <?xml version="1.0"?>
    <project>
      	<modelVersion>4.0.0</modelVersion>
      	<groupId>camj</groupId>
      	<artifactId>CamjWorkflowRH</artifactId>
      	<version>1.0-SNAPSHOT</version>
      	<packaging>jar</packaging>
      	<name>WorkflowRH</name>
            <scm>[...]</scm>
     
    	<developers>[...]</developers>
     
    	<distributionManagement>[...]</distributionManagement>
     
        <build>
    		<defaultGoal>install</defaultGoal>  
    		<finalName>${artifactId}-${version}</finalName>
    		<sourceDirectory>${basedir}/trunk/src</sourceDirectory>
     
    		<testSourceDirectory>${basedir}/trunk/src/test</testSourceDirectory>
     
        	<plugins>
    	      	<plugin>
    	        	<groupId>org.apache.maven.plugins</groupId>
    	      	   	<artifactId>maven-compiler-plugin</artifactId>
    						<configuration>
    	        		<source>1.5</source>
    			        <target>1.5</target>
    	      		</configuration>
    	      	<plugin>
    	   	</plugins>
      	</build>
     
    	<dependencies>
        	<dependency>
          		<groupId>junit</groupId>
          		<artifactId>junit</artifactId>
          		<version>3.8.1</version>
          		<scope>test</scope>
        	</dependency>
    	</dependencies>
     
        <reporting>
        	<plugins>
     
    <!-- *** GENERATION JAVADOC *** -->
        		<plugin>
    	            <groupId>org.apache.maven.plugins</groupId>
    	            <artifactId>maven-javadoc-plugin</artifactId>
    	            <configuration>
                  		<show>public</show>
    	            </configuration> 
             	</plugin>
     
    <!-- *** GENERATION CHECKSTYLE *** -->
            	<plugin>
              		<groupId>org.apache.maven.plugins</groupId>
              		<artifactId>maven-checkstyle-plugin</artifactId>
    	        </plugin>
     
    <!-- *** GENERATION FINDBUGS *** -->
    			<plugin>
    			    <groupId>org.codehaus.mojo</groupId>
    			    <artifactId>findbugs-maven-plugin</artifactId>
    			    <configuration>
    			    	<threshold>Normal</threshold> <!-- |Normal|Low|High|Exp|Ignore -->
    			      	<effort>Default</effort> <!-- Min|Default|Max -->
    			    </configuration>
    			</plugin>
     
    <!-- *** GENERATION DES RAPPORTS PAR DEFAUT *** -->
        	    <plugin>
    	    	    <groupId>org.apache.maven.plugins</groupId>
    	        	<artifactId>maven-project-info-reports-plugin</artifactId>      	
    	        </plugin>
     
    <!-- *** GENERATION DES SOURCES NAVIGABLES EN HTML *** -->	        
    		   	<plugin>
    		    	<groupId>org.codehaus.mojo</groupId>
    		    	<artifactId>jxr-maven-plugin</artifactId>	    	
    		   	</plugin>	        
          	</plugins>
      	</reporting>
    </project>
    tout le reste étant configuré par défaut comme par exemple JXR qui par défaut si il y a le plugin Javadoc fait le lien en direct sans lui spécifier quoique ce soit.

    Essaye-le et tiens-nous au courant.

  6. #6
    Nouveau membre du Club
    Inscrit en
    Mai 2004
    Messages
    49
    Détails du profil
    Informations forums :
    Inscription : Mai 2004
    Messages : 49
    Points : 25
    Points
    25
    Par défaut
    J'ai modifié mon pom et je n'ai tjs pas de index.html

    Ca peut avoir un lien avec Eclipse / Windows ou pas ?

  7. #7
    Membre actif Avatar de dvicente72
    Profil pro
    Inscrit en
    Novembre 2004
    Messages
    213
    Détails du profil
    Informations personnelles :
    Âge : 52
    Localisation : France

    Informations forums :
    Inscription : Novembre 2004
    Messages : 213
    Points : 226
    Points
    226
    Par défaut [MAVEN 2 & Eclipse] Génération du site
    là, j'avoue que je séche.

    je n'ai jamais eu ce genre de probleme.

    c'est quand même curieux que tu n'ais pas un index.html dans ton répertoire {project.dir}/target/site.

    Est-ce que tu peux lancer sous DOS , en te positionnant sur ton projet :

    mvn -e -X site>maven.log

    et poster le log généré pour voir ce que ça donne ?

  8. #8
    Nouveau membre du Club
    Inscrit en
    Mai 2004
    Messages
    49
    Détails du profil
    Informations forums :
    Inscription : Mai 2004
    Messages : 49
    Points : 25
    Points
    25
    Par défaut
    En exécutant la ligne de commande que tu m'as donné, il a généré un index.Html... ca viendrait de Eclipse ?

  9. #9
    Membre actif Avatar de dvicente72
    Profil pro
    Inscrit en
    Novembre 2004
    Messages
    213
    Détails du profil
    Informations personnelles :
    Âge : 52
    Localisation : France

    Informations forums :
    Inscription : Novembre 2004
    Messages : 213
    Points : 226
    Points
    226
    Par défaut [MAVEN 2 & Eclipse] Génération du site
    ben normalement non, moi j'utilise Eclipse pour débugger des plugins Maven et ça ne m'a jamais posé de probleme.

    D'un autre côté, je n'utilise pas Maven dans Eclipse.

    Je préfere le faire dans une fenêtre DOS.

  10. #10
    Nouveau membre du Club
    Inscrit en
    Mai 2004
    Messages
    49
    Détails du profil
    Informations forums :
    Inscription : Mai 2004
    Messages : 49
    Points : 25
    Points
    25
    Par défaut
    Ok, ben je vais rester en ligne de comm, ca marche mieux... Merci a tous, je vais poser delestage hein

  11. #11
    Membre actif Avatar de dvicente72
    Profil pro
    Inscrit en
    Novembre 2004
    Messages
    213
    Détails du profil
    Informations personnelles :
    Âge : 52
    Localisation : France

    Informations forums :
    Inscription : Novembre 2004
    Messages : 213
    Points : 226
    Points
    226
    Par défaut
    mets-le plutôt en résolu, on sait jamais, ça peut arriver à d'autres.

    Qu'en penses-tu ?

  12. #12
    Nouveau membre du Club
    Inscrit en
    Mai 2004
    Messages
    49
    Détails du profil
    Informations forums :
    Inscription : Mai 2004
    Messages : 49
    Points : 25
    Points
    25
    Par défaut
    J'ai trouvé

    En fait, j'avais la version 0.0.5 de maven integrator (sous Eclipse), et la version 0.0.9 le génère

    Tout bête, mais bon, au cas où, je le passe en résolu, exact

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. [maven2] génération de site multi modules
    Par jpalcluc dans le forum Maven
    Réponses: 11
    Dernier message: 25/07/2007, 16h02
  2. eclipse génération .war
    Par moog14 dans le forum Eclipse Java
    Réponses: 1
    Dernier message: 16/07/2007, 14h28
  3. Maven 2 et Eclipse!
    Par Sniper37 dans le forum Maven
    Réponses: 11
    Dernier message: 27/02/2007, 09h13
  4. Réponses: 12
    Dernier message: 30/12/2006, 16h49
  5. [Maven] Fonctionne sous Eclipse ?
    Par pamic dans le forum Eclipse Java
    Réponses: 2
    Dernier message: 14/09/2005, 16h49

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo