Index of /~anoop/distrib/autoindex

Icon  Name                    Last modified      Size  Description
[DIR] Parent Directory - [   ] autoindex.tar.gz 10-Jan-2011 20:39 3.8K [   ] df_for_texfile.sh 10-Jan-2011 20:39 124 [   ] find_index_terms.sh 10-Jan-2011 20:39 345 [TXT] ignore 10-Jan-2011 20:39 33 [   ] insert-index.pl 10-Jan-2011 20:39 2.7K [   ] joint_counts.pl 10-Jan-2011 20:39 816 [   ] lik.pl 10-Jan-2011 20:39 1.1K [   ] produce_bigram_count..> 10-Jan-2011 20:39 567 [   ] readme.html 10-Jan-2011 20:39 2.4K [   ] restore.sh 10-Jan-2011 20:39 73 [   ] tscore.pl 10-Jan-2011 20:39 618

Autoindex
---------

Prerequisites:
detex-2.7 or later.
perl v5 or later.

Install:

% gzip -dc autoindex.tar.gz | tar xvf - 
will unpack the files into a directory autoindex

Runtime:

Step 0
------

add the autoindex directory to your PATH variable.

Step 1
------

make copies of your tex files that you wish to index. you should
maintain a seperate directory for the autoindexed tex files so
that you have a copy of your original files before autoindex can mess
with your files.

Step 2
------

run 
% find_index_terms.sh <root.tex>

where root.tex is the file that defines documentclass and includes all
other files.

this creates a file index.terms

this step might take a while to finish for a big file.

edit index.terms to remove any entries below some threshold. the
scores will help in telling you which entries are more likely to
be valid index terms.

for each pair of words, Step 4 will create an index entry of the form
\index{b!a}. optionally you can add a ! before any line for which you
wish to generate an entry \index{a b} instead.

Step 3
------

Create a new root.tex file which contains the appropriate autoindex
instructions (see the LaTeX manual for more info). call this
root_ind.tex

Step 4
------

examine the file `ignore' in the autoindex directory, and copy 
to the directory where you have your tex files. edit the file
to add words to ignore.

Step 5
------

for each tex file to which you wish to add index entries: 

% insert_index.pl <index.terms> <texfile>

This will create a copy of <texfile> to <texfile.bak> and add
index entries to <texfile>. 

Now latex root_ind.tex to generate the document with an index.

You can now edit your original texfiles and copy them over and repeat
Step 4 as many times as you want to automatically generate the
makeindex version of your document.

restore.sh copies back the original versions to ensure a safe version
for future iterations.

------
Anoop Sarkar
<anoop at linc.cis.upenn.edu>