diff options
author | Karl Berry <karl@freefriends.org> | 2008-06-09 20:12:47 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2008-06-09 20:12:47 +0000 |
commit | c2ded34c4ac6a32fbed94b870481aaf9667fc227 (patch) | |
tree | cc7b9d209a306f44bc962ea8d7357307b9460ca9 /Master/tlpkg/bin/htmltext | |
parent | 07b1dd24a6c6ca7ac335c56b3cc3127bd7910619 (diff) |
move autoupdate scripts to new tools bindir
git-svn-id: svn://tug.org/texlive/trunk@8623 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/bin/htmltext')
-rwxr-xr-x | Master/tlpkg/bin/htmltext | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/Master/tlpkg/bin/htmltext b/Master/tlpkg/bin/htmltext new file mode 100755 index 00000000000..c41eb2490fe --- /dev/null +++ b/Master/tlpkg/bin/htmltext @@ -0,0 +1,23 @@ +#!/bin/sh +# $Id$ +# Public domain. Originally written 2003, Karl Berry. +# Dump a url (or -stdin) to text using lynx. + +PATH=/usr/local/bin:$PATH + +HOME=/tmp; export HOME +TERM=vt100; export TERM +: ${LYNX_CFG=/home/tug/.lynxcfg}; export LYNX_CFG +# just contains the line JUSTIFY:FALSE. + +test $# -eq 0 && set - -stdin + +for url in "$@"; do + # when we add -width=79, tables are formatted badly. + # -dump lists url's like this with -stdin (lynx 2.8.4, linux): + # file://localhost/tmp/89inmk/FAQ/german + # Since the reference list is useful, we fix it up by hand instead of + # using -nolist. + lynx -dump -nocolor -hiddenlinks=ignore "$url" \ + | sed 's,file://localhost/tmp/[a-zA-Z0-9]*/,,' +done |