1
0
mirror of https://frontier.innolan.net/rainlance/c-ares.git synced 2025-10-05 06:19:28 +00:00
Files
c-ares/workman2
Carsten Larsen 2811e30d49 Release 1.12.0
2017-04-12 01:21:06 +02:00

33 lines
491 B
Bash

#! /bin/sh
# Taken from the tz distribution.
# Tell groff to emit SGR escape sequences (ANSI color escapes).
GROFF_SGR=1
export GROFF_SGR
echo ".am TH
.hy 0
.na
..
.rm }H
.rm }F" | nroff -man - ${1+"$@"} | perl -ne '
binmode STDIN, '\'':encoding(utf8)'\'';
binmode STDOUT, '\'':encoding(utf8)'\'';
chomp;
s/.\010//g;
s/\s*$//;
if (/^$/) {
$sawblank = 1;
next;
} else {
if ($sawblank && $didprint) {
print "\n";
$sawblank = 0;
}
print "$_\n";
$didprint = 1;
}
'