New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Maven site integration does not work with Maven Site Plugin 3.4 #125
Comments
I believe that @grdryn discovered that the Also, do you know how to register more than one file extension for a site module? I couldn't figure it out. |
On a closer read, I see that you are saying that the Asciidoctor site module might not be compatible with the newest Maven Site Plugin release. Are there any release notes that document what changed in this release? |
I just figured out that it doesnt work with 3.4 by debugging my setups. I am not sure what changed in 3.4 but from all I know a bunch of internal things like doxia got changed. I will ask on the Maven developer hangout this week about multiple extensions since I dont know myself. We could also ask on the dev list. |
Great! |
Btw. in terms of the file extension.. I think it would be better to make it a config option for the plugin .. rather than supporting multiple. That should be easy to implement. |
Forget what I said.. its already there. |
I take it back again... it seems like the site integration does not use the parameter to set the extension into account. |
Seems like multiple extensions is not supported at the moment but could be added. We discussed it a bit more here https://www.youtube.com/watch?v=yfY-kbHj4VU |
Thanks @mosabua. The time offset for that discussion seems to be around 9:10. |
PR #130 created with a fix for m-site-p 3.4 (Doxia 1.6) I don't know what is the multiple file extension question |
#125 added ParserModule implementation needed by Doxia 1.6/m-site-p 3.4
@hboutemy it would be good if filenames with the extensions .adoc as well as .asciidoc are picked up automatically when locating them in src/site/asciidoc |
My file extensions are .adoc and they are not picked up by maven-site-plugin 3.4 |
I don't understand how to register multiple file extensions for a site module. If someone knows how to do it, please feel free to file a pull request. It will be most appreciated :) |
You need to wait for the next release of the doxia plugin. Once that is done you will be able to simply do:
|
Great news!! |
@paranoiabla what version of doxia? I might be able to push for a release on the Maven dev list. If its not already in progress.. |
The 2 pullrequests I have linked above (for |
I'm not sure if my problem is relating to this one. Using Maven site plugin 3.4, I can get .adoc files in src/site/asciidoc to build into standalone themed HTML files. However, if a file includes other files, the included files do not get resolved. For instance, in src/site/asciidoc/ I have book.adoc, which includes chapters/installation.adoc, chapters/administration.adoc, etc. If I build book.adoc using an execution of the asciidoctor plugin, it works. However, if I try to build it using mvn site, the includes do not get resolved. Presumably there is a step where everything gets concatenated into one big .adoc before building, and that is not happening with the 'mvn site' target. I am happy to file this as a separate issue, but it seems that it might be related here so I thought I would post here first. |
@mstanleyjones The problem here is that the configuration of Asciidoctor within the Maven Site plugin is extremely limited. Likely what is happening is that the includes are not being found because Asciidoctor is being invoked without the proper base directory, and a custom base directory cannot be set. We really need to figure out how we can configure Asciidoctor when it is invoked via the Maven Site plugin. In essence, we need a configuration block like the regular plugin has. A first step here is to get includes working in the example project so that we know it at least works (and can explore the problem in depth). See https://github.com/asciidoctor/asciidoctor-maven-examples/tree/master/asciidoc-maven-site-example |
@mstanleyjones As I suspected, the baseDir is not being set and is therefore defaulting to the root of the project. Thus, to resolve an include, it has to begin with |
See #180 |
I believe this issue was resolved in 1.5.2. We're addressing some of the other points raised in this thread as part of 1.5.3. |
Awesome news. Looking forward to the new release! |
To reproduce just upgrade the version of the Maven Site Plugin in https://github.com/asciidoctor/asciidoctor-maven-examples/blob/master/asciidoc-site-example/pom.xml
and you will no longer get the html versions of your asciidoc generated..
The text was updated successfully, but these errors were encountered: