Concerning the requirements that new "includedocument" block macro should meet I'd like to come back to my initial considerations in hope that you still share them (see also https://github.com/asciidoctor/asciidoctor/issues/894):
1. A subdocument is an self-sufficient entity. It has it's own resources images etc. and can be processed individually. It can be packed and deployed everywhere in the source tree. 2. A master document includes subdocuments. If all subdocuments compile without error the master does so too. 3. The only property distinguishing a master and a subdocument is that the first includes the second. Thus it is possible that they exchange roles: the master can become subdocument and the subdocument can become master without changing any relative paths. Jens PS: I post this at several places PPS: In reply to: http://discuss.asciidoctor.org/Workaround-to-resolve-imagesdir-when-using-includes-td1517.html As I understand you do not want to modify the behaviour of include and rather introduce a new "includedocument" command. In deed there are some good technical arguments not to do so: A preprocessor directive should do nothing else then sourcing another file. Still from the user point of view we want to distinguish 2 cases: - "include" including a file (which is a resource of a document, like pictures, source code etc.) without changing any variables. - "includedocument" including another (sub-)document which has its own resources, it's own pictures etc. It needs to have a modified root directory. Access to the parent root directory would be useful too. Distinguishing a) and b) is trivial: a sourced subdocument has a title ("= Title") this is case b). A sourced file without title is case a). So I still do not see the benefit of introducing a new command for b) (although I could happily live with it). -- You received this message because you are subscribed to the Google Groups "asciidoc" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/asciidoc. For more options, visit https://groups.google.com/groups/opt_out.
