{"issue":{"state":"open","created_at":"2011-12-02T16:11:15Z","updated_at":"2011-12-09T09:24:34Z","comments":1,"user":{"gravatar_id":"f2faa0110b8f29db899392cef389b207","id":1231235,"url":"https://api.github.com/users/lilalinda","avatar_url":"https://secure.gravatar.com/avatar/f2faa0110b8f29db899392cef389b207?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"lilalinda"},"body":"Hi,\r\n\r\nI'm using Maven 3.0.3 and found the maven-latex-plugin to be exactly what I was looking for to prepare my already existing manual in LaTeX for inclusion in the Maven generated site.  I wanted to use the feature of maven-latex-plugin to compile my source code into PDF, HTML single page and HTML multiple pages.  So I followed you \"Complex Example\" (see http://akquinet.github.com/maven-latex-plugin/example_complex.html).  However, when I have more than one execution, only the first one succeeds (which I can inspect under `target/m2latex` if I turn `<cleanUp>` off).  The result of target/m2latex is then copied to the `<outputDirectory>` for each execution.\r\n\r\nTo put it differently, if I have the following in my POM:\r\n\r\n            <plugin>\r\n                <groupId>de.akquinet.maven</groupId>\r\n                <artifactId>maven-latex-plugin</artifactId>\r\n                <version>1.1</version>\r\n                <inherited>false</inherited>\r\n                <executions>\r\n                    <!--<execution>-->\r\n                        <!--<phase>site</phase>-->\r\n                        <!--<goals>-->\r\n                            <!--<goal>latex</goal>-->\r\n                        <!--</goals>-->\r\n                    <!--</execution>-->\r\n                    <execution>\r\n                        <id>HTML multipage</id>\r\n                        <configuration>\r\n                            <settings>\r\n                                <outputDirectory>html_multipage</outputDirectory>\r\n                                <tex4htCommandArgs>\r\n                                    <tex4htCommandArg>tex4ht,2</tex4htCommandArg>\r\n                                    <tex4htCommandArg></tex4htCommandArg>\r\n                                    <tex4htCommandArg></tex4htCommandArg>\r\n                                    <tex4htCommandArg>-interaction=nonstopmode --src-specials</tex4htCommandArg>\r\n                                </tex4htCommandArgs>\r\n                            </settings>\r\n                        </configuration>\r\n                        <phase>site</phase>\r\n                        <goals>\r\n                            <goal>tex4ht</goal>\r\n                        </goals>\r\n                    </execution>\r\n                    <execution>\r\n                        <id>HTML singlepage</id>\r\n                        <configuration>\r\n                            <settings>\r\n                                <outputDirectory>html_singlepage</outputDirectory>\r\n                                <tex4htCommandArgs>\r\n                                    <tex4htCommandArg>tex4ht,1</tex4htCommandArg>\r\n                                    <tex4htCommandArg></tex4htCommandArg>\r\n                                    <tex4htCommandArg></tex4htCommandArg>\r\n                                    <tex4htCommandArg>-interaction=nonstopmode --src-specials</tex4htCommandArg>\r\n                                </tex4htCommandArgs>\r\n                            </settings>\r\n                        </configuration>\r\n                        <phase>site</phase>\r\n                        <goals>\r\n                            <goal>tex4ht</goal>\r\n                        </goals>\r\n                    </execution>\r\n                </executions>\r\n            </plugin>\r\n\r\nthen the `HTML multipage` target gets created successfully but not the `HTML singlepage` target.  Instead, the multipage result gets copied into the `target/site/html_singlepage/` directory.  If I switch the order, the singlepage result is generated and copied into the `target/site/html_multipage/` directory.\r\n\r\nNow I tried to specify different `<tempDirectory>` entries for each execution, but the same thing happened.  If I turn `<cleanUp>` off, I see the output of the first execution in both temp directories.\r\n\r\nAny thoughts?\r\nThanks,\r\nLinda\r\n","assignee":null,"id":2429674,"labels":[],"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"number":1,"title":"Using multiple executions, only the first one succeeds","closed_at":null,"html_url":"https://github.com/akquinet/maven-latex-plugin/issues/1","url":"https://api.github.com/repos/akquinet/maven-latex-plugin/issues/1","milestone":null},"action":"created","comment":{"created_at":"2011-12-09T09:24:34Z","updated_at":"2011-12-09T09:24:34Z","user":{"gravatar_id":"154ac601eb64b2743eb8870011813efb","id":537746,"url":"https://api.github.com/users/cerker","avatar_url":"https://secure.gravatar.com/avatar/154ac601eb64b2743eb8870011813efb?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"cerker"},"body":"Linda,\r\n\r\nwhat should happen is:\r\n\r\n1. If the tempDirectory (default: target/m2latex) exists, it is deleted\r\n2. Contents of LaTeX source folder (src/site/latex) are copied to the (now empty) tempDirectory.\r\n3. The first execution is processed and the results (e.g. *.pdf, *.html, *.css files) are copied to the outputDirectory (e.g. target/site/html_multipage).\r\n4. The tempDirectory is deleted, if cleanUp is true.\r\n5. if there is another execution, go to 1.\r\n\r\nI.e. the tempDirectory will contain only the stuff that was generated during the last execution, if it is not specified differently from the others. This also means, each execution works on a clean tempDirectory.\r\n\r\nIf I run the example provided with the maven-latex-plugin in module test-site, this works for me. As a result I get: \r\n* target/site/pdf/Doc1.pdf, target/site/pdf/Doc2.pdf and target/site/pdf/subfolder/Doc3.pdf; \r\n* target/site/html_singlepage/ with one html file containing the whole document and one css file for each document\r\n* target/site/html_multipage/ with several html files and one css file for each document; with Doc1.html containing only the title and the contents as well as one html file for each section (e.g. Doc1se1.html).\r\n\r\nI am creating the site with Maven 3.0.3 and \"mvn clean site\". I commented out the pdf execution, as in your example.\r\n\r\nIf it is still not working for you, could you please post the output and/or clone the project and build the site in the test-site module?\r\n\r\nHere is my output:\r\n\r\n```\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] Building Maven LaTeX Plugin - Test Site 1.0\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] \r\n[INFO] --- maven-site-plugin:2.0.1:site (default-site) @ test-site ---\r\n[WARNING] No URL defined for the project - decoration links will not be resolved\r\n[WARNING] No URL defined for the project - decoration links will not be resolved\r\n[INFO] \r\n[INFO] --- maven-latex-plugin:1.1:tex4ht (HTML multipage) @ test-site ---\r\n[INFO] settings.getOutputDirectory(): /Users/carsten/devel/maven-latex-plugin/test-site/target/site/html_multipage\r\n[INFO] Processing LaTeX file /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex/Doc1.tex\r\n[INFO] Processing LaTeX file /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex/Doc2.tex\r\n[INFO] Processing LaTeX file /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex/subfolder/Doc3.tex\r\n[INFO] \r\n[INFO] --- maven-latex-plugin:1.1:tex4ht (HTML singlepage) @ test-site ---\r\n[INFO] settings.getOutputDirectory(): /Users/carsten/devel/maven-latex-plugin/test-site/target/site/html_singlepage\r\n[INFO] Deleting existing directory /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex\r\n[INFO] Processing LaTeX file /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex/Doc1.tex\r\n[INFO] Processing LaTeX file /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex/Doc2.tex\r\n[INFO] Processing LaTeX file /Users/carsten/devel/maven-latex-plugin/test-site/target/m2latex/subfolder/Doc3.tex\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] BUILD SUCCESS\r\n[INFO] ------------------------------------------------------------------------\r\n\r\n```\r\n","id":3076903,"url":"https://api.github.com/repos/akquinet/maven-latex-plugin/issues/comments/3076903"}}