File: latex2html.in

package info (click to toggle)
swi-prolog 3.1.0-2
  • links: PTS
  • area: main
  • in suites: slink
  • size: 8,772 kB
  • ctags: 12,869
  • sloc: ansic: 43,657; perl: 12,577; lisp: 4,359; sh: 1,534; makefile: 798; awk: 14
file content (27 lines) | stat: -rw-r--r-- 418 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/sh

libdir=@LIBDIR@
PL=@PL@

case "$1" in
    -pl)
	goal=welcome
	toplevel=prolog
	;;
    *)
	in=`echo "$1" | sed 's/\.tex$//'`
	if [ -z "$in" ]; then
	    echo "Usage: $0 file"
	    echo "   or: $0 -pl"
	    exit 1
	fi
	goal="latex2html('$in')"
	toplevel=halt
	;;
esac

$PL -L0 -G0 -T0 \
    -f none \
    -p library=$libdir \
    -g "load_files(library(latex2html),[silent(true)]),$goal" \
    -t "$toplevel"