The jDocBook plugin currently makes an assumption that you have just a single
book per project. If you have multiple books, you need to create projects,
one per book. I want to change that to allow multiple books per project.
However, this change entails some major changes to how configuration gets
defined and handled.
Currently an example configuration would look like:
jdocbook {
masterSourceDocumentName = 'GradleUserGide.xml'
translations = ['de-DE']
format {
name = 'html_single'
finalName = 'index.html'
}
format {
name = 'html'
finalName = 'index.html'
}
format {
name = 'pdf'
}
}
Let's say I want to add a guide for plugin development as well. I am thinking
that the config syntax that works the best in term of user feel is:
jdocbook {
translations = ['de-DE']
format {
name = 'html_single'
finalName = 'index.html'
}
format {
name = 'html'
finalName = 'index.html'
}
userGuide {
baseDirectory = 'src/main/jdocbook/userGuide'
masterSourceDocumentName = 'GradleUserGide.xml'
format {
name = 'pdf'
}
}
pluginDevGuide {
baseDirectory = 'src/main/jdocbook/pluginDevGuide'
masterSourceDocumentName = 'GradlePluginDevGide.xml'
}
}
We have 2 specific guides here, the user guide and the plugin development
guide. Each have some specific configuration as well as sharing some common
configuration. Both have been translated into German; both should get
rendered
into html and html-single styles.
So the difficulties... That syntax is extremely difficult (maybe just given my
poor Groovy skillz) to mesh with the existing syntax in terms of applying it.
So the first question is just how important backwards-compatibility is here.
If uber-important, i will need to adjust the syntax i think accordingly since,
as I said, its beyond my Groovy skills to manage that here.
Also, I am not sure how the "book names" can be handled since they are dynamic
(not a discrete set). Does this maybe need to be an explicit Map syntax? Or
can I manage converting that syntax above into a Map structure keyed by book
name ("userGuide", "pluginDevGuide")? Maybe via creative use of delegate?
Is it better to explicitly group the shared configuration in any way?
jdocbook {
shared {
translations = ['de-DE']
format {
name = 'html_single'
finalName = 'index.html'
}
...
}
...
}
Does that gain me anything?
--
Steve Ebersole <[email protected]>
http://hibernate.org
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email