From: Stephen Gaito <stephen@perceptisys.co.uk>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Purpose/use of loadsetup interface *.xml files
Date: Thu, 23 Feb 2017 08:13:01 +0000 [thread overview]
Message-ID: <20170223081301.744a717a@nn01> (raw)
Hello,
Problem:
--------
I am having trouble getting a simple module's documentation to
load setup information.
Question:
---------
Where can I find up-to-date documentation on the load setup
interface file use and required format?
Background:
----------
I have a current standalone ConTeXt installation with only luatex(mkiv)
and all modules (updated yesterday).
I intend to write a number of ConTeXt modules to assist in my work.
My first module is ConTests a simple wrapper around lua's lunatest
framework. ( GitHub: stephengaito/ConTests )
As I work I like to write unit-tests and documentation
concurrently with the code itself (as much as possible).
I am basing my documentation effort on t-fancybreak.mkvi. As such I
have written a setup interface file t-contests.xml.
My directory structure is:
t-contests/tex/context/interface/third/t-contests.xml
t-contests/tex/context/third/ConTests/t-contests.mkiv
t-contests/tex/context/third/ConTests/t-contests.lua
I am building my module documentation using:
mtxrun --script modules --process t-contexts.mkiv
(inside the t-contests/tex/context/third/ConTests directory).
The resluting t-contests-mkiv.pdf file has 'MISSING SETUP' where I
would expect the \showsetup{loadSuite} output to be placed.
The mtxrun log output has the line:
xml > core > load error in [id: setups:, file: .xml]: empty xml file
I interpret this to mean that my interface file was not found (or
possibly not correctly specified).
The relevant contents of t-contests.mkiv are:
------------
%M \usemodule[contests]
%M \loadsetups[t-contests.xml]
\writestatus{loading}{ConTeXt User Module / ConTests}
%D \subject{Implementation}
\unprotect
\ctxloadluafile{t-contests}
%D \macros{loadSuite}
%D
%D \showsetup{loadSuite}
\def\loadSuite#1{\directlua{thirddata.contests.lunatest.loadSuite('#1.lua')}}
\protect \endinput
-----------------
The contents of t-contests.xml is:
--------------
<?xml version="1.0" encoding="UTF-8"?>
<!-- This is the ConTeXt interface for the t-contests module -->
<!-- We have based the structure of this interface on the t-fancybreak module -->
<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="en" version="2010.06.21">
<cd:command name="loadSuite" generated="yes" file="t-contests.mkiv">
<cd:sequence>
<cd:string value="loadSuite"?>
</cd:sequence>
<cd:arguments>
<cd:content n="1" optional="no"/>
</cd:arguments>
</cd:command>
</cd:interface>
-----------------
Any and all assistance would be greatly appreciated.
Regards,
Stephen Gaito
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
reply other threads:[~2017-02-23 8:13 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170223081301.744a717a@nn01 \
--to=stephen@perceptisys.co.uk \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).