# Re: [NTG-context] beta


Hans Hagen wrote:
>>
>> A few weeks back Taco said that a lua based bib module is at least a
>> few months away
>> (http://archive.contextgarden.net/message/20090312.084338.8be52e4c.en.html).
>> Is that still the case? Without the bib module, I will not be able to
>> use MKIV in real projects, and would basically be stuck at the current
>> beta.
>
> hm, can you check what fails?

! Undefined control sequence.
<argument> \alltoclevels

That is because the publication list is a <list> and it has to redefine
some of the internal filtering routines so you can say

\placepublicationlist[criterium=]

There are two big bad macros. First, there is this redefinition
of \dosetfilterlevel  (that became needed after some point due to
changes in context).

%%%%%%%%%%%%%%%%%%%%%%%%5
\def\patcheddosetfilterlevel#1#2% beware: this one is \let
{\bgroup
\ignoresectionconversion % this is vital for bib !
\global\chardef\alltoclevels\plusone
\global\chardef\alltoclevels\plusone
\else
\else
\fi
\fi\fi\fi\fi
\xdef\currentlevel
\fi
\egroup}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

The second is this macro, which does the actual filtering:

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\def\filllocalpublist%
{\let\dosetfilterlevel\patcheddosetfilterlevel
\dosettoclevel\??li{pubs}%
\let\dosetfilterlevel\normaldosetfilterlevel
\global\let\glocalpublist\empty
\doloop
{\doifdefinedelse
{\r!cross cite-\jobname-\recurselevel}
{\doifreferencefoundelse
{cite-\jobname-\recurselevel}
{...@ea\doifreglevelelse\@EA[\currentlocationreference]
{\currenttextreference}\glocalpublist}{}}
{}}%
{\exitloop}}%
\let\localpublist\glocalpublist}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

___________________________________________________________________________________