Asciidoc and dependency management
Posted by
Michael_M on
Sep 23, 2015; 5:24pm
URL: https://discuss.asciidoctor.org/Asciidoc-and-dependency-management-tp3751.html
I'm trying to figure out the best way to include documentation from other (independent) modules. I'm hoping that someone has done this before and can share some pointers.
Let's assume that my project P depends on modules A and B. There are 3 Git repositories: P, A and B each reside in their own Git repository containing the source code and the documentation.
Just as in the code, the dependencies are specific to a particular version.
So I want all include:: directives that point to A, to point to a specific git branch of A.
There are 2 approaches I am considering:
1. Use attributes in the asciidoc document in P, and point to the specific version.
E.g:
:repo_a:
https://raw.githubusercontent.com/username/project_A/v3.5My concern with this approach: what happens with the includes directives in A? And images?
Approach 2: Use Gradle to handle the dependencies. I assume that Gradle would have to download the correct branch of A and B. I'm not sure how this could be setup with directory structures.
Any thoughts?