Remove HTML-formatted man pages
This commit is contained in:
parent
aa94548c71
commit
7e17853326
3 changed files with 6 additions and 1 deletions
|
|
@ -125,6 +125,7 @@ sub addman {
|
|||
|
||||
my($enc, $dec) = decodeman($dat, $locale);
|
||||
print "Invalid encoding or empty file: $path\n" and return if !$enc;
|
||||
print "Ignoring HTML-formatted page: $path\n" and return if $dec =~ /^\s*<(?:html|head|\!DOCTYPE)/;
|
||||
|
||||
$db->do(q{INSERT INTO contents (hash, content) VALUES(decode(?, 'hex'),?)}, {}, $hash, $dec)
|
||||
if !$db->selectrow_arrayref(q{SELECT 1 FROM contents WHERE hash = decode(?, 'hex')}, {}, $hash);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue