[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
FYI: texi2dvi: hevea's info file splitting
From: |
Akim Demaille |
Subject: |
FYI: texi2dvi: hevea's info file splitting |
Date: |
Tue, 27 Jun 2006 19:02:14 +0200 |
User-agent: |
Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux) |
Index: ChangeLog
from Akim Demaille <address@hidden>
* util/defs.in ($latex_paragraph): New.
* util/latex2html.test (input.tex): Make it big enough to trigger
the info file splitting.
* util/texi2dvi (move_to_dest): Accept several arguments.
(run_hevea): Use it to move the whole family.
Index: util/defs.in
===================================================================
RCS file: /cvsroot/texinfo/texinfo/util/defs.in,v
retrieving revision 1.6
diff -u -u -r1.6 defs.in
--- util/defs.in 27 Jun 2006 16:23:19 -0000 1.6
+++ util/defs.in 27 Jun 2006 17:01:05 -0000
@@ -303,6 +303,54 @@
)
}
+# $latex_paragraph
+# ----------------
+# Some lengthy LaTeX.
+# grep -E '^[a-zA-Z]+$' /usr/share/dict/words | sed 200q | pr --page-width=76
--column=5 --omit-header
+latex_paragraph='
+A Acrux Aegean Ahmad Albany
+AOL Actaeon Aelfric Ahmadabad Albee
+Aachen Acton Aeneas Ahmed Alberio
+Aaliyah Acts Aeneid Ahriman Albert
+Aaron Acuff Aeolus Aida Alberta
+Abbas Ada Aeroflot Aiken Alberto
+Abbasid Adam Aeschylus Aileen Albigensian
+Abbott Adams Aesculapius Aimee Albion
+Abby Adan Aesop Ainu Albireo
+Abdul Adana Afghan Airedale Albuquerque
+Abe Adar Afghanistan Airedales Alcatraz
+Abel Addams Afghans Aisha Alcestis
+Abelard Adderley Africa Ajax Alcibiades
+Abelson Addie African Akbar Alcmena
+Aberdeen Addison Africans Akhmatova Alcoa
+Abernathy Adela Afrikaans Akihito Alcott
+Abidjan Adelaide Afrikaner Akita Alcuin
+Abigail Adele Afrikaners Akkad Alcyone
+Abilene Adeline Afro Akron Aldan
+Abner Aden Afrocentrism Al Aldebaran
+Abraham Adenauer Afros Ala Alden
+Abram Adhara Ag Alabama Alderamin
+Abrams Adidas Agamemnon Alabaman Aldo
+Absalom Adirondack Agassi Alabamans Aldrin
+Abuja Adirondacks Agassiz Alabamian Alec
+Abyssinia Adkins Agatha Alabamians Aleichem
+Abyssinian Adler Aggie Aladdin Alejandra
+Ac Adolf Aglaia Alamo Alejandro
+Acadia Adolfo Agnes Alamogordo Alembert
+Acapulco Adolph Agnew Alan Aleppo
+Accra Adonis Agni Alana Aleut
+Acevedo Adonises Agra Alar Aleutian
+Achaean Adrian Agricola Alaric Alex
+Achebe Adriana Agrippa Alaska Alexander
+Achernar Adriatic Agrippina Alaskan Alexandra
+Acheson Adrienne Aguilar Alaskans Alexandria
+Achilles Advent Aguinaldo Alba Alexei
+Aconcagua Adventist Aguirre Albania Alexis
+Acosta Advents Agustin Albanian Alfonso
+Acropolis Advil Ahab Albanians Alfonzo
+'
+
+
# Turn on shell traces when VERBOSE is set.
if test -n "$VERBOSE"; then
set -x
Index: util/latex2html.test
===================================================================
RCS file: /cvsroot/texinfo/texinfo/util/latex2html.test,v
retrieving revision 1.2
diff -u -u -r1.2 latex2html.test
--- util/latex2html.test 27 Jun 2006 16:23:19 -0000 1.2
+++ util/latex2html.test 27 Jun 2006 17:01:05 -0000
@@ -24,12 +24,22 @@
set -e
-# For the creation of auxiliary files.
-create_input_tex <<EOF
-\tableofcontents
-\section{First}
-\section{Second}
-EOF
+# Force the creation of auxiliary files.
+# Force it to be big enough to trigger the info file splitting.
+{
+ echo "\tableofcontents"
+ for section in 1 2 3 4 5 6
+ do
+ echo "\section{$i}"
+ for subsection in 1 2 3 4 5 6
+ do
+ echo "\subsection{$i}"
+ echo "$latex_paragraph"
+ done
+ done
+} |
+create_input_tex
+
# run_hevea_check FORMAT OPTIONS
# ------------------------------
@@ -43,6 +53,13 @@
# Testing the local build mode.
TEXI2DVI_pass --batch --$format "$@" input.tex
+ # Compute the expected output.
+ outfiles=input.$out
+ case $format in
+ info) outfiles="$outfiles input.info-1 input.info-2";;
+ esac
+
+ # Compute the aux files.
case $format:$@ in
*clean* ) auxfiles='';;
*tidy* ) auxfiles='input.t2d';;
@@ -51,8 +68,8 @@
* ) auxfiles='';;
esac
# There should only be the expected output and the source file.
- assert_files $auxfiles input.$out input.tex
- rm -fr $auxfiles input.$out
+ assert_files input.tex $outfiles $auxfiles
+ rm -fr $outfiles $auxfiles
}
for opt in "" "--clean" "--tidy"
Index: util/texi2dvi
===================================================================
RCS file: /cvsroot/texinfo/texinfo/util/texi2dvi,v
retrieving revision 1.88
diff -u -u -r1.88 texi2dvi
--- util/texi2dvi 27 Jun 2006 16:29:54 -0000 1.88
+++ util/texi2dvi 27 Jun 2006 17:01:05 -0000
@@ -505,8 +505,9 @@
esac
}
-# move_to_dest FILE
-# -----------------
+
+# move_to_dest FILE...
+# --------------------
# Move the FILE to the place where the user expects it. FILE can be
# the principal output (in which case -o directly apply), or an auxiliary
# file with the same base name.
@@ -514,18 +515,21 @@
{
local dest
- case $tidy:$oname in
- true:) dest=$orig_pwd;;
- false:) dest=;;
- *:*) dest=$(output_base_name "$1");;
- esac
- if test ! -f "$1"; then
- error 1 "no such file or directory: $1"
- fi
- if test -n "$dest"; then
- verbose "Copying $1 to $dest"
- cp -p "$1" "$dest"
- fi
+ for file
+ do
+ case $tidy:$oname in
+ true:) dest=$orig_pwd;;
+ false:) dest=;;
+ *:*) dest=$(output_base_name "$file");;
+ esac
+ if test ! -f "$file"; then
+ error 1 "no such file or directory: $file"
+ fi
+ if test -n "$dest"; then
+ verbose "Copying $file to $dest"
+ cp -p "$file" "$dest"
+ fi
+ done
}
@@ -1178,7 +1182,11 @@
verbose "running $run_hevea"
if eval "$run_hevea" >&5; then
- move_to_dest "$out_base"
+ case $1 in
+ html|text) move_to_dest "$out_base";;
+ info) # There can be foo.info-1, foo.info-2 etc.
+ move_to_dest "$out_base"*;;
+ esac
else
error 1 "$hevea exited with bad status, quitting."
fi
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- FYI: texi2dvi: hevea's info file splitting,
Akim Demaille <=