On 21 May 2014 00:34, wm <[email protected]> wrote: > I'm developing a simple command to wrap AsciiDoc compiler for multi > documents into HTML5 documentation for Windows and FreeBSD. The application > manage custom themes ([header] + [footer] AsciiDoc conf sections, style > sheets and javascript code), scan a source directory and sub-directories for > '.asciidoc' files and generate the HTML pages in another directory. It > currently works and the generated documentation is very good. I also created > a filter to implement SyntaxHighlighter by Alex Gorbatchew instead of the > default 'source-highligher' that use a special codelist block [sourcecode, > posattrs]. > > There are few things I don't understand. The application has a per-project > xml configuration file where set input/output directories, customize command > flags in calling asciidoc.py command, choose backends and document type, > custom AsciiDoc configuration files, etc. Those configuration parameters are > the same for all documents in the projects, so if a custom configuration > file is specified it will be inserted on AsciiDoc command line for all > documents in the project as '-f <prj-path>/my_custom.conf'. > > Now, I'm trying to se 'tabsize' attribute to '4' and some other attributes > for all source documents. I created a common configuration file. The content > of that file is as follow > > [miscellaneous] > tabsize=4 > > [attributes] > source-highlighter=pygments > icons= > linkcss= > > what happens is that 'icons' and 'linkcss' takes effect, while 'tabsize' and > 'source-highlighter' are ignored. I have to put them in the header of each > document or on the command line as '-a tabsize=4 -a > source-highlighter=pygments'.
Sounds like the document probably sets tabsize and source-highlighter, setting on the command line overrides the document, but the document overrides the configuration file. Cheers Lex > > Is that a bug or a feature? > > I also tested other solutions like including the configuration file in the > document header with both 'include' and 'include1' macros, but the content > is put verbating in the document, i.e. the content is not processed by > AsciiDoc. > > This is not a big problem, I put them on command line, but in Windows the > command line can be 2048 or 8192 bytes (depending on version) and it already > is near 2048 byte (there are many defined attributes containing absolute > paths). On FreeBSD I'm not sure what is the max length of command line but > I'm pretty sure it's more than 8192, perhaps is the same as in Linux. > > I know if I change 'asciidoc.conf' in AsciiDoc distribution all works, but I > don't want to change the default AsciiDoc configuration files to avoid > overwriting it with an update. > > > -- > 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/d/optout. -- 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/d/optout.
