gnugo-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnugo-devel] [new file] doc/gtp-commands.sed


From: Thien-Thi Nguyen
Subject: [gnugo-devel] [new file] doc/gtp-commands.sed
Date: Wed, 30 Oct 2002 04:26:21 -0800

this is the new file used by the Makefile target gtp-commands.texi (see
other mail for patch).  because some of the whitespace is significant,
let me know if there are problems in the transmission and i'll resend
uuencoded.

thi

__________________________________________________________
# gtp-commands.sed (edit in -*-shell-script-*- mode)
# Author: Thien-Thi Nguyen <address@hidden>

# Look for function headers.
/\* Function: /,/^{/!d

# Remove cruft.
/^static int/d
/^{/d
/^ \*\//d
s/(char.*)//g

# Hold comment lines, deleting them from pattern space for now.
/.\*/{
 s/^..//
 H
 d
}

# When we see the function name, merge hold space, in the process
# generating proper texinfo @cindex, @item and @example formatting.
# We use repeated `x' commands instead of the simpler `i' to avoid
# requiring a `d' (which would render this script non-composable).
/^gtp_/{
 s/^\(.*\)$/@cindex \1\
@item \1\
\
@example/
 G
 x
 s/.*/\
@end example\
/
 x
 G
 x
 s/.*//
 x
}

# gtp-commands.sed ends here




reply via email to

[Prev in Thread] Current Thread [Next in Thread]