#!/usr/bin/perl -w use strict; use File::Basename; my $rcs = '$Id: formatav.pl,v 1.8 2001/09/01 03:01:55 gilles Exp $ ' ; # '; my $myself = $0; my $date = scalar(localtime()); my %formats = ( html => 'HTML', htm => 'HTM', ps => 'PostScript', pdf => 'PDF', sgml => 'SGML', txt => 'ASCII', tex => 'TeX', lyx => 'LyX', info => 'Info', ); usage(), exit unless @ARGV; my $file = basename(shift(@ARGV), '.sgml'); print < EOF foreach my $format (keys(%formats)) { my $path = "$format/${file}.${format}"; if (-f $path) { print < EOF }else{ print "$formats{$format}\n"; } } my $path = "man/${file}.1"; if (-f $path) { print < EOF }else{ print "Man "; } print < EOF sub usage { print <