summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-10-25 17:26:03 +0000
committerKarl Berry <karl@freefriends.org>2010-10-25 17:26:03 +0000
commit9752d7c7fcada2b36d40595174afcf6ecb48bb91 (patch)
tree5f39c96e11bf8a8e26e2f15bde1cda94439aa374
parent9643a7acc463ef254a9172bc983f052a2ee540e5 (diff)
generate tlpkg/texcatalogue.keywords from enhanced catalogue dump, for use in tlmgr keyword searching
git-svn-id: svn://tug.org/texlive/trunk@20198 c570f23f-e606-0410-a88d-b1316a301751
-rwxr-xr-xMaster/texmf/scripts/texlive/tlmgr.pl2
-rwxr-xr-xMaster/tlpkg/bin/tl-update-auto43
-rwxr-xr-xMaster/tlpkg/bin/tl-update-keywords (renamed from Master/tlpkg/bin/parse-texcatalogue-keywords)0
-rw-r--r--Master/tlpkg/tlpsrc/texlive-docindex.tlpsrc8
4 files changed, 40 insertions, 13 deletions
diff --git a/Master/texmf/scripts/texlive/tlmgr.pl b/Master/texmf/scripts/texlive/tlmgr.pl
index 1e18da8f8d1..440627c89d0 100755
--- a/Master/texmf/scripts/texlive/tlmgr.pl
+++ b/Master/texmf/scripts/texlive/tlmgr.pl
@@ -1174,7 +1174,7 @@ sub action_path {
sub load_taxonomy_datafile {
init_local_db();
my $taxonomy;
- my $fpath = $localtlpdb->root . "/texmf/scripts/texlive/tc-dump";
+ my $fpath = $localtlpdb->root . "/tlpkg/texcatalogue.keywords";
if (! -r $fpath) {
tlwarn("tlmgr: taxonomy file $fpath not readable.\n");
return;
diff --git a/Master/tlpkg/bin/tl-update-auto b/Master/tlpkg/bin/tl-update-auto
index 382d72d73d6..5eef7a66728 100755
--- a/Master/tlpkg/bin/tl-update-auto
+++ b/Master/tlpkg/bin/tl-update-auto
@@ -3,7 +3,6 @@
# Public domain. Originally written 2003, Karl Berry.
#
# Deal with files that are automatically updated in one way or another.
-# New files need to be added manually, doesn't happen often enough.
PATH=/usr/local/gnu/bin:/usr/local/bin:$PATH; export PATH
umask 0
@@ -31,6 +30,7 @@ trap "rm -f $temp*" 0 1 2 15
update_list=
add_list=
+
# autogenerate README.EN from readme.html.
#
if $config_scripts_only; then :; else
@@ -41,7 +41,8 @@ else
$chicken $cp $temp readme-txt.dir/README.EN
update_list="$update_list readme-txt.dir/README.EN"
fi
-fi
+fi # !config_scripts_only
+
# modes.mf from elsewhere on tug.org.
#
@@ -55,7 +56,8 @@ else
$chicken $cp $modesmaster $modesslave
update_list="$update_list $modesslave"
fi
-fi
+fi # !config_scripts_only
+
# texinfo.tex from elsewhere on tug.org.
#
@@ -69,7 +71,8 @@ else
$chicken $cp $tximaster $txislave
update_list="$update_list $txislave"
fi
-fi
+fi # !config_scripts_only
+
# fontname from elsewhere on tug.org.
#
@@ -116,7 +119,8 @@ for basef in $files; do
update_list="$update_list $fontnameencslavef"
fi
done
-fi
+fi # !config_scripts_only
+
# config.guess/sub/etc. from elsewhere on tug.org, mirrored from GNU.
# ylwrap comes from automake; ltmain.sh comes from libtool. For those
@@ -198,8 +202,7 @@ if test -z "$chicken" && $man_update; then
update_list="$update_list $mandir"
add_list=`svn status $mandir | sed -n 's/^\? *//p'`
fi
-
-fi # config_scripts_only
+fi # !config_scripts_only
# doc.html.
@@ -207,8 +210,6 @@ fi # config_scripts_only
if $config_scripts_only; then :; else
$mydir/tl-update-docindex | tee $temp.doc \
| grep -v '<small>Generated' >$temp.doc.new
-cp $temp.doc.new /tmp/x
-
#
grep -v '<small>Generated' doc.html >$temp.doc.cur
if $diff $temp.doc.cur $temp.doc.new >$temp.doc.diff; then
@@ -217,8 +218,32 @@ else
$chicken $cp $temp.doc.new doc.html
update_list="$update_list doc.html"
fi
+fi # !config_scripts_only
+
+
+# texcatalogue.keywords
+#
+if $config_scripts_only; then :; else
+cat_dump=/tmp/tc.xml
+rm -f $cat_dump.new
+wget -nv ftp://tug.ctan.org/ftpmaint/az/texcatalogue.xml -O $cat_dump.new \
+&& mv $cat_dump.new $cat_dump
+# if ftp fails, we'll reprocess the old dump, but that should be harmless.
+$mydir/tl-update-keywords -input $cat_dump | tee $temp.keywords \
+| grep -v '# Generated' >$temp.keywords.new
+#
+keywordfile=tlpkg/texcatalogue.keywords
+grep -v '# Generated' $keywordfile >$temp.keywords.cur
+if $diff $temp.keywords.cur $temp.keywords.new >$temp.keywords.diff; then
+ $verbose " $keywordfile ok."
+else
+ $chicken $cp $temp.keywords.new $keywordfile
+ update_list="$update_list $keywordfile"
fi
+fi # !config_scripts_only
+
+# svn commits.
status=0
if test -z "$update_list"; then
echo "$0: nothing to update."
diff --git a/Master/tlpkg/bin/parse-texcatalogue-keywords b/Master/tlpkg/bin/tl-update-keywords
index 52de2036601..52de2036601 100755
--- a/Master/tlpkg/bin/parse-texcatalogue-keywords
+++ b/Master/tlpkg/bin/tl-update-keywords
diff --git a/Master/tlpkg/tlpsrc/texlive-docindex.tlpsrc b/Master/tlpkg/tlpsrc/texlive-docindex.tlpsrc
index 27991dba630..7829ff2b3d7 100644
--- a/Master/tlpkg/tlpsrc/texlive-docindex.tlpsrc
+++ b/Master/tlpkg/tlpsrc/texlive-docindex.tlpsrc
@@ -1,5 +1,7 @@
category TLCore
-shortdesc top-level TeX Live doc.html
-longdesc This file is regenerated as needed, which is often,
-longdesc so we make it a separate package.
+shortdesc top-level TeX Live doc.html et al.
+longdesc These files are regenerated as needed, which is often,
+longdesc so we make them a separate package. See the tl-update-auto
+longdesc script for the process.
docpattern +f doc.html
+docpattern +f tlpkg/texcatalogue.keywords