auctex
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [AUCTeX] run makeindex to generate glossary


From: Ralf Angeli
Subject: Re: [AUCTeX] run makeindex to generate glossary
Date: Sun, 08 Jun 2008 14:28:22 +0200

* Frederik Fischbach (2008-06-08) writes:

> I run emacs 22.1 for editing LaTeX documents using AucTeX. This works
> fine except for generating glossaries.
>
> In LaTeX I use the packages "glossaries".
> If editing myfile.tex, to generate the entries I've to run 'makeindex
> -s myfile.ist -t myfile.glg -o myfile.gls myfile.glo'.
> But in emacs running 'Index' via C-c C-c, it just tries "Running
> 'Index' on 'myfile' with 'makeindex myfile'", which fails ("Couldn't
> find input index file myfile nor myfile.idx").
>
> At the moment it's a pain to generate the glossary from emacs (on
> windows) every time like this:
> C-c C-c Other RET cygstart "c:\Programme\MiKTeX
> 2.7\miktex\bin\makeindex.exe" -s myfile.ist -t myfile.glg -o
> myfile.gls myfile.glo RET
>
> How to tell emacs/auctex to generate a glossary using makeindex and
> not to try to generate a "normal" index? I want to avoid this long
> command...

You could add a "Glossary" entry to the command list (untested):

(eval-after-load "tex"
  (add-to-list 'TeX-command-list
               '("Glossary" "makeglossaries %s" TeX-run-command nil
                 (latex-mode) :help "Create glossaries")))

If I find the time I might put something like this into a style file for
glossaries.sty.  (Note that I used the Perl script provided by the
glossaries package as a command instead of a makeindex call.)

Alternatively you could customize `TeX-command-list' and change the
command for "Index".  But then you will not see updates to the default
value of the variable.

> Next, it would be good to tell AucTeX to automatically detect whether
> to run makeindex (actually generate the glossary) and/or BibTeX. If I
> invoke AucTeX 3 times with C-c C-c, it will run latex 2 times and the
> viewer.

This is nontrivial with the current implementation.  Once we get support
for tool chains it should be easier.

-- 
Ralf




reply via email to

[Prev in Thread] Current Thread [Next in Thread]