Alternative to glossaries?

UPDATE: I have been using glassaries for some time now, and kind of got used to it. It's not as bad as I at first thought.

Is there a nicer alternative to glossaries package? It's a pita to use. Documentation is lacking examples, some commands don't do anything (like \glssee), it is hard to customize (why can't I make my glossary a simple section?), it is stateful - I have to call makeglossaries in a certain place, and also the syntax for defining new entries is ugly:

 \newglossaryentry{blah}{name=blah, description={blabh lbah blah}}


It's like xml.

No offense to the creators, but I am just curious if anyone else feels this way and if there are alternatives?

• I hope you both mean "lovely" for "like xml" – David Carlisle Jun 13 '12 at 22:58
• \glssee does ‘something’ if you use it after \makeglossaries. – mhp Jun 14 '12 at 8:42
• You are writing a book-type document and want your glossary to appear in a simple section? Try, for example, \usepackage[section=section, numberedsection]{glossaries}. – mhp Jun 14 '12 at 8:47
• Undoubtedly, the glossaries package is rather complex, but, in my experience, it enables you to realize nearly anything related to glossaries, lists of acronyms, notations etc. Since the glossaries package includes tree-like styles it might also serve as a replacement for many index-related packages. Moreover, I haven’t seen any package that supports xindy in a comparable manner. – mhp Jun 14 '12 at 8:52
• Would you prefer to have a command that had at least 18 optional arguments? That's the alternative to key=value syntax. The glossaries package comes with 21 sample files and a beginners' guide for people who find the main user manual too large. If something doesn't work, provide a MWE rather than just saying it's a pita. – Nicola Talbot May 5 '13 at 11:45

Here is an alternative to a pita.

\documentclass[11pt]{book}
\usepackage{lstdoc,lipsum}
\begin{document}
\makeatletter
\def\alist{}

\let\sort\lst@BubbleSort
}

\def\gentry#1#2{%
\long\expandafter\gdef\csname#1\endcsname{\textbf{#1}: #2}
\sort\alist
}

\def\PrintGlossary{%
\@for \i:=\alist\do{%
\csname\i\endcsname\par}
}
%example
\gentry{electrolyte}{Substance containing free ions that make t
he substance electrically conductive}
\gentry{battery}{\lipsum[3]}
\gentry{poles}{\lipsum[1]}
% print the glossary
\section{Glosary}
\PrintGlossary

\battery
\makeatother
\end{document}


It provides one non-xml command:

  \gentry{<term>}{<description>}


...and it does not need Perl. Enjoy!

• Thanks, but it's missing the equivalent of the \gls command, and I would also like to do cross-referencing. E.g. car see vehicle – Andriy Drozdyuk Jun 13 '12 at 21:45
• \gentry{car}{see vehicle}. – Yiannis Lazarides Jun 13 '12 at 21:47
• So.. how would I use a glossary term in text? Or do you mean that this is only for defining a glossary section at the end, without page numbers of where it occurred? – Andriy Drozdyuk Jun 15 '12 at 3:28

I changed the code above, so that you can do cross references:

\documentclass[11pt]{book}
\usepackage{lstdoc,lipsum}
\usepackage{hyperref}
\begin{document}
\makeatletter
\def\alist{}

\let\sort\lst@BubbleSort
}

\def\gentry#1#2{%
\long\expandafter\gdef\csname.#1\endcsname{\hypertarget{target#1}{\textbf{#1}: #2}}
\sort\alist
}

\def\gentryP#1#2#3{%
\long\expandafter\gdef\csname.#1\endcsname{\hypertarget{target#1}{\textbf{#1}: #2}}
\sort\alist
}

\def\PrintGlossary{%
\section{Glosary}
\

\@for \i:=\alist\do{%
\csname.\i\endcsname\par}

\newpage
}

%example
\gentry{electrolyte}{Substance containing free ions that make t
he substance electrically conductive}
% use gentryP if the plural is irregular
\gentryP{battery}{\lipsum[3]}{batteries}
\gentry{poles}{\lipsum[1]}

% print the glossary
\PrintGlossary

\section{normal text}

\electrolyte s are used nearly everywhere.

\newpage

\battery is the singular. but sometimes you need the plural \batteries.

\makeatother
\end{document}


The datagidx package in the datatool bundle might a good solution for you.

Datagidx is an improved version of the code discussed in this article.

Here is some package documentation and a sample document.

I have not tried this myself yet, but it is the one I have settled on trying as my first approach because I don't like that the glossaries package has external dependencies.

Edit: I have now tried this on one project. It works works nicely but can be a slight bit confusing at first, but I haven't tried any of the other solutions to this so I can't really compare them.