You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Fabian Unfried (JIRA)" <ji...@codehaus.org> on 2011/02/12 18:56:22 UTC

[jira] Created: (MPDF-47) docDescriptors of other locales than default are ignored for pdf generation

docDescriptors of other locales than default are ignored for pdf generation
---------------------------------------------------------------------------

                 Key: MPDF-47
                 URL: http://jira.codehaus.org/browse/MPDF-47
             Project: Maven 2.x PDF Plugin
          Issue Type: Bug
    Affects Versions: 1.1
         Environment: Maven 2.2.1, Windows 7 (and NetBeans 6.9.1)
            Reporter: Fabian Unfried
         Attachments: pdf.xml, pdf_de.xml

If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.


Try following:

Create a directory layout like:

+- src/
   +- site/
      +- xdoc/
      |  +- index.xml     (some default language content)
      |  +- help.xml     (some default language content)
      |  +- foo.xml     (some default language content)
      |
      +- de/
      |  +- xdoc/
      |     +- index.xml     (some different content than default language)
      |     +- help.xml     (some different content than default language)
      |     +- foo.xml     (some different content than default language)
      +- site.xml         (Default site descriptor)
      +- site_de.xml      (German site descriptor)
      +- pdf.xml          (Default pdf descriptor)
      +- pdf_de.xml       (German pdf descriptor)


Content of pdf.xml:

see attachment pdf.xml


Content of pdf_de.xml:

see attachment pdf_de.xml


Content of pom.xml:


...
	<build>
		...
		<plugins>
			...
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-site-plugin</artifactId>
				<version>2.2</version>
				<configuration>
					<locales>en,de</locales>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-pdf-plugin</artifactId>
				<version>1.1</version>
				<configuration>
					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
					<includeReports>false</includeReports>
					<aggregate>true</aggregate>
					<locales>en,de</locales>
				</configuration>
				<executions>
					<execution>
						<id>pdf</id>
						<phase>site</phase>
						<goals>
							<goal>pdf</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>


If you now execute

mvn site

or

mvn pdf:pdf

and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MPDF-47) docDescriptors of other locales than default are ignored for pdf generation

Posted by "Fabian Unfried (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MPDF-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=255805#action_255805 ] 

Fabian Unfried commented on MPDF-47:
------------------------------------

Sorry, wasn't aware of that Jira has some table syntax which is very similar to the directory layout you're using on the site and pd plugin page, so here again the directory layout:

- src/
-- site/
--- xdoc/
---- index.xml (some default language content)
---- help.xml (some default language content)
---- foo.xml (some default language content)
--- de/
---- xdoc/
----- index.xml (some different content than default language)
----- help.xml (some different content than default language)
----- foo.xml (some different content than default language)
--- site.xml (Default site descriptor)
--- site_de.xml (German site descriptor)
--- pdf.xml (Default pdf descriptor)
--- pdf_de.xml (German pdf descriptor)

> docDescriptors of other locales than default are ignored for pdf generation
> ---------------------------------------------------------------------------
>
>                 Key: MPDF-47
>                 URL: http://jira.codehaus.org/browse/MPDF-47
>             Project: Maven 2.x PDF Plugin
>          Issue Type: Bug
>    Affects Versions: 1.1
>         Environment: Maven 2.2.1, Windows 7 (and NetBeans 6.9.1)
>            Reporter: Fabian Unfried
>         Attachments: pdf.xml, pdf_de.xml
>
>
> If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.
> Try following:
> Create a directory layout like:
> +- src/
>    +- site/
>       +- xdoc/
>       |  +- index.xml     (some default language content)
>       |  +- help.xml     (some default language content)
>       |  +- foo.xml     (some default language content)
>       |
>       +- de/
>       |  +- xdoc/
>       |     +- index.xml     (some different content than default language)
>       |     +- help.xml     (some different content than default language)
>       |     +- foo.xml     (some different content than default language)
>       +- site.xml         (Default site descriptor)
>       +- site_de.xml      (German site descriptor)
>       +- pdf.xml          (Default pdf descriptor)
>       +- pdf_de.xml       (German pdf descriptor)
> Content of pdf.xml:
> see attachment pdf.xml
> Content of pdf_de.xml:
> see attachment pdf_de.xml
> Content of pom.xml:
> ...
> 	<build>
> 		...
> 		<plugins>
> 			...
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-site-plugin</artifactId>
> 				<version>2.2</version>
> 				<configuration>
> 					<locales>en,de</locales>
> 				</configuration>
> 			</plugin>
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-pdf-plugin</artifactId>
> 				<version>1.1</version>
> 				<configuration>
> 					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
> 					<includeReports>false</includeReports>
> 					<aggregate>true</aggregate>
> 					<locales>en,de</locales>
> 				</configuration>
> 				<executions>
> 					<execution>
> 						<id>pdf</id>
> 						<phase>site</phase>
> 						<goals>
> 							<goal>pdf</goal>
> 						</goals>
> 					</execution>
> 				</executions>
> 			</plugin>
> 		</plugins>
> 	</build>
> If you now execute
> mvn site
> or
> mvn pdf:pdf
> and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MPDF-47) docDescriptors of other locales than default are ignored for pdf generation

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MPDF-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=265711#action_265711 ] 

Lukas Theussl commented on MPDF-47:
-----------------------------------

It would be nice if you could attach a self-contained example project.

> docDescriptors of other locales than default are ignored for pdf generation
> ---------------------------------------------------------------------------
>
>                 Key: MPDF-47
>                 URL: http://jira.codehaus.org/browse/MPDF-47
>             Project: Maven 2.x PDF Plugin
>          Issue Type: Bug
>    Affects Versions: 1.1
>         Environment: Maven 2.2.1, Windows 7 (and NetBeans 6.9.1)
>            Reporter: Fabian Unfried
>         Attachments: pdf.xml, pdf_de.xml
>
>
> If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.
> Try following:
> Create a directory layout like:
> {noformat}
> +- src/
>    +- site/
>       +- xdoc/
>       |  +- index.xml     (some default language content)
>       |  +- help.xml     (some default language content)
>       |  +- foo.xml     (some default language content)
>       |
>       +- de/
>       |  +- xdoc/
>       |     +- index.xml     (some different content than default language)
>       |     +- help.xml     (some different content than default language)
>       |     +- foo.xml     (some different content than default language)
>       +- site.xml         (Default site descriptor)
>       +- site_de.xml      (German site descriptor)
>       +- pdf.xml          (Default pdf descriptor)
>       +- pdf_de.xml       (German pdf descriptor)
> {noformat}
> Content of pdf.xml:
> see attachment pdf.xml
> Content of pdf_de.xml:
> see attachment pdf_de.xml
> Content of pom.xml:
> {code:xml}
> ...
> 	<build>
> 		...
> 		<plugins>
> 			...
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-site-plugin</artifactId>
> 				<version>2.2</version>
> 				<configuration>
> 					<locales>en,de</locales>
> 				</configuration>
> 			</plugin>
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-pdf-plugin</artifactId>
> 				<version>1.1</version>
> 				<configuration>
> 					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
> 					<includeReports>false</includeReports>
> 					<aggregate>true</aggregate>
> 					<locales>en,de</locales>
> 				</configuration>
> 				<executions>
> 					<execution>
> 						<id>pdf</id>
> 						<phase>site</phase>
> 						<goals>
> 							<goal>pdf</goal>
> 						</goals>
> 					</execution>
> 				</executions>
> 			</plugin>
> 		</plugins>
> 	</build>
> {code}
> If you now execute
> {noformat}
> mvn site
> {noformat}
> or
> {noformat}
> mvn pdf:pdf
> {noformat}
> and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MPDF-47) docDescriptors of other locales than default are ignored for pdf generation

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MPDF-47?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dennis Lundberg updated MPDF-47:
--------------------------------

    Description: 
If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.


Try following:

Create a directory layout like:

{noformat}
+- src/
   +- site/
      +- xdoc/
      |  +- index.xml     (some default language content)
      |  +- help.xml     (some default language content)
      |  +- foo.xml     (some default language content)
      |
      +- de/
      |  +- xdoc/
      |     +- index.xml     (some different content than default language)
      |     +- help.xml     (some different content than default language)
      |     +- foo.xml     (some different content than default language)
      +- site.xml         (Default site descriptor)
      +- site_de.xml      (German site descriptor)
      +- pdf.xml          (Default pdf descriptor)
      +- pdf_de.xml       (German pdf descriptor)
{noformat}


Content of pdf.xml:

see attachment pdf.xml


Content of pdf_de.xml:

see attachment pdf_de.xml


Content of pom.xml:


{code:xml}
...
	<build>
		...
		<plugins>
			...
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-site-plugin</artifactId>
				<version>2.2</version>
				<configuration>
					<locales>en,de</locales>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-pdf-plugin</artifactId>
				<version>1.1</version>
				<configuration>
					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
					<includeReports>false</includeReports>
					<aggregate>true</aggregate>
					<locales>en,de</locales>
				</configuration>
				<executions>
					<execution>
						<id>pdf</id>
						<phase>site</phase>
						<goals>
							<goal>pdf</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
{code}


If you now execute

{noformat}
mvn site
{noformat}

or

{noformat}
mvn pdf:pdf
{noformat}

and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.

  was:
If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.


Try following:

Create a directory layout like:

+- src/
   +- site/
      +- xdoc/
      |  +- index.xml     (some default language content)
      |  +- help.xml     (some default language content)
      |  +- foo.xml     (some default language content)
      |
      +- de/
      |  +- xdoc/
      |     +- index.xml     (some different content than default language)
      |     +- help.xml     (some different content than default language)
      |     +- foo.xml     (some different content than default language)
      +- site.xml         (Default site descriptor)
      +- site_de.xml      (German site descriptor)
      +- pdf.xml          (Default pdf descriptor)
      +- pdf_de.xml       (German pdf descriptor)


Content of pdf.xml:

see attachment pdf.xml


Content of pdf_de.xml:

see attachment pdf_de.xml


Content of pom.xml:


...
	<build>
		...
		<plugins>
			...
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-site-plugin</artifactId>
				<version>2.2</version>
				<configuration>
					<locales>en,de</locales>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-pdf-plugin</artifactId>
				<version>1.1</version>
				<configuration>
					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
					<includeReports>false</includeReports>
					<aggregate>true</aggregate>
					<locales>en,de</locales>
				</configuration>
				<executions>
					<execution>
						<id>pdf</id>
						<phase>site</phase>
						<goals>
							<goal>pdf</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>


If you now execute

mvn site

or

mvn pdf:pdf

and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.


> docDescriptors of other locales than default are ignored for pdf generation
> ---------------------------------------------------------------------------
>
>                 Key: MPDF-47
>                 URL: http://jira.codehaus.org/browse/MPDF-47
>             Project: Maven 2.x PDF Plugin
>          Issue Type: Bug
>    Affects Versions: 1.1
>         Environment: Maven 2.2.1, Windows 7 (and NetBeans 6.9.1)
>            Reporter: Fabian Unfried
>         Attachments: pdf.xml, pdf_de.xml
>
>
> If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.
> Try following:
> Create a directory layout like:
> {noformat}
> +- src/
>    +- site/
>       +- xdoc/
>       |  +- index.xml     (some default language content)
>       |  +- help.xml     (some default language content)
>       |  +- foo.xml     (some default language content)
>       |
>       +- de/
>       |  +- xdoc/
>       |     +- index.xml     (some different content than default language)
>       |     +- help.xml     (some different content than default language)
>       |     +- foo.xml     (some different content than default language)
>       +- site.xml         (Default site descriptor)
>       +- site_de.xml      (German site descriptor)
>       +- pdf.xml          (Default pdf descriptor)
>       +- pdf_de.xml       (German pdf descriptor)
> {noformat}
> Content of pdf.xml:
> see attachment pdf.xml
> Content of pdf_de.xml:
> see attachment pdf_de.xml
> Content of pom.xml:
> {code:xml}
> ...
> 	<build>
> 		...
> 		<plugins>
> 			...
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-site-plugin</artifactId>
> 				<version>2.2</version>
> 				<configuration>
> 					<locales>en,de</locales>
> 				</configuration>
> 			</plugin>
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-pdf-plugin</artifactId>
> 				<version>1.1</version>
> 				<configuration>
> 					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
> 					<includeReports>false</includeReports>
> 					<aggregate>true</aggregate>
> 					<locales>en,de</locales>
> 				</configuration>
> 				<executions>
> 					<execution>
> 						<id>pdf</id>
> 						<phase>site</phase>
> 						<goals>
> 							<goal>pdf</goal>
> 						</goals>
> 					</execution>
> 				</executions>
> 			</plugin>
> 		</plugins>
> 	</build>
> {code}
> If you now execute
> {noformat}
> mvn site
> {noformat}
> or
> {noformat}
> mvn pdf:pdf
> {noformat}
> and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MPDF-47) docDescriptors of other locales than default are ignored for pdf generation

Posted by "Tim Rademacher (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MPDF-47?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tim Rademacher updated MPDF-47:
-------------------------------

    Attachment: fix_locale_select.diff

Added a patch for this. Please verify.
                
> docDescriptors of other locales than default are ignored for pdf generation
> ---------------------------------------------------------------------------
>
>                 Key: MPDF-47
>                 URL: https://jira.codehaus.org/browse/MPDF-47
>             Project: Maven 2.x PDF Plugin
>          Issue Type: Bug
>    Affects Versions: 1.1
>         Environment: Maven 2.2.1, Windows 7 (and NetBeans 6.9.1)
>            Reporter: Fabian Unfried
>         Attachments: fix_locale_select.diff, pdf_de.xml, pdf.xml
>
>
> If you have a multi language maven site and you'll try to build a pdf also with multiple locales only the default pdf.xml docDescriptor will be used for generating the pdfs.
> Try following:
> Create a directory layout like:
> {noformat}
> +- src/
>    +- site/
>       +- xdoc/
>       |  +- index.xml     (some default language content)
>       |  +- help.xml     (some default language content)
>       |  +- foo.xml     (some default language content)
>       |
>       +- de/
>       |  +- xdoc/
>       |     +- index.xml     (some different content than default language)
>       |     +- help.xml     (some different content than default language)
>       |     +- foo.xml     (some different content than default language)
>       +- site.xml         (Default site descriptor)
>       +- site_de.xml      (German site descriptor)
>       +- pdf.xml          (Default pdf descriptor)
>       +- pdf_de.xml       (German pdf descriptor)
> {noformat}
> Content of pdf.xml:
> see attachment pdf.xml
> Content of pdf_de.xml:
> see attachment pdf_de.xml
> Content of pom.xml:
> {code:xml}
> ...
> 	<build>
> 		...
> 		<plugins>
> 			...
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-site-plugin</artifactId>
> 				<version>2.2</version>
> 				<configuration>
> 					<locales>en,de</locales>
> 				</configuration>
> 			</plugin>
> 			<plugin>
> 				<groupId>org.apache.maven.plugins</groupId>
> 				<artifactId>maven-pdf-plugin</artifactId>
> 				<version>1.1</version>
> 				<configuration>
> 					<outputDirectory>${project.reporting.outputDirectory}</outputDirectory>
> 					<includeReports>false</includeReports>
> 					<aggregate>true</aggregate>
> 					<locales>en,de</locales>
> 				</configuration>
> 				<executions>
> 					<execution>
> 						<id>pdf</id>
> 						<phase>site</phase>
> 						<goals>
> 							<goal>pdf</goal>
> 						</goals>
> 					</execution>
> 				</executions>
> 			</plugin>
> 		</plugins>
> 	</build>
> {code}
> If you now execute
> {noformat}
> mvn site
> {noformat}
> or
> {noformat}
> mvn pdf:pdf
> {noformat}
> and compare the two generated pdfs you'll see that the table of contents is the one from the pdf.xml in both pdfs. I guess in this case the file pdf_de.xml isn't used at anytime during the build, because the build (mvn site or mvn pdf:pdf) is also successful if you have syntax errors in the pdf_de.xml file, e.g. leave a item tag open in that file and build again.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira