Currently, URLs are resolved through the urllib. However, this doesn't take XML catalogs into account.
I would propose the following steps:
Introduce an -c / --catalog option. If the user adds this, the given catalog is investigated.
Check for the environment variable XML_CATALOG_FILES. This variable can contain one or more catalogs separated by space.
If neither options given nor env variable is set, use the standard root catalog at /etc/xml/catalog.
ATM it seems there is no direct way to resolve a URI through lxml (see also http://stackoverflow.com/a/7229470). However, I've found http://lxml.de/resolvers.html which may be of some value. If there is no easy way we could use the xmlcatalog directly like this:
$ xmlcatalog CATALOG URI_TO_RESOLVE
Add the information about how to resolve URIs into the manpage.
Implemented in feature/xmlcatalog, is that alright so far? It's a bit hard to test correctly and I'm not quite sure whether I got the order in dbxincluder.xinclude.get_target right.
Currently, URLs are resolved through the urllib. However, this doesn't take XML catalogs into account.
I would propose the following steps:
-c
/--catalog
option. If the user adds this, the given catalog is investigated.XML_CATALOG_FILES
. This variable can contain one or more catalogs separated by space./etc/xml/catalog
.ATM it seems there is no direct way to resolve a URI through lxml (see also http://stackoverflow.com/a/7229470). However, I've found http://lxml.de/resolvers.html which may be of some value. If there is no easy way we could use the
xmlcatalog
directly like this:Add the information about how to resolve URIs into the manpage.