Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site ncoast.UUCP Path: utzoo!watmath!clyde!bonnie!akgua!whuxlm!harpo!decvax!cwruecmp!hal!ncoast!bsa From: bsa@ncoast.UUCP (Brandon Allbery) Newsgroups: net.sources Subject: Manual page for context Message-ID: <728@ncoast.UUCP> Date: Sat, 8-Jun-85 09:12:03 EDT Article-I.D.: ncoast.728 Posted: Sat Jun 8 09:12:03 1985 Date-Received: Mon, 10-Jun-85 21:56:15 EDT Reply-To: bsa@ncoast.UUCP (Brandon Allbery) Organization: North Coast Xenix, Cleveland, OH Lines: 140 Many thanks to ..decvax!mcvax!enea!tut!jty (Jyrki Yli-Nokari), who presented me with the following manual page for the context program. --bsa -- Brandon Allbery, Unix Consultant -- 6504 Chestnut Road, Independence, OH 44131 decvax!cwruecmp!ncoast!bsa; ncoast!bsa@case.csnet; +1 216 524 1416; 74106,1032 ========================> Trekkies have Warped minds. <======================= --------------------------------- cut here ----------------------------------- # Here is a bare-bones man page for your context(1) # Do whatever you want with it (or post it to the net). # # -- Jyrki # # # This is a shell archive. Remove anything before this line, then # unpack it by saving it in a file and typing "sh file". (Files # unpacked will be owned by you and have default permissions.) # # This archive contains: # context.1 echo x - context.1 cat > "context.1" << '//E*O*F context.1//' .TH CONTEXT 1 "6 June 1985" .\" $Header: context.c,v 1.4 85/05/27 21:51:34 bsa Exp $ .SH NAME context \- find context of lines .SH SYNOPSIS .B context [ .B nr_of_lines ] .PP .SH DESCRIPTION .I Context finds the context of located text. It accepts for example cc(1) diagnostics as standard input and gives you the context. .SH OPTIONS If the optional argument; a number `nr_of_lines' is given, context(1) prints that much context before and after the line in question. .SH EXAMPLES .nf % cc foo.c |& context ************** * "foo.c", line 5: warning: old-fashioned initialization: use = ***** main() { int i; * long ix.v; i = getpid(); if (ix_v = getchar() == EOF) ************** * "foo.c", line 5: syntax error ***** main() { int i; * long ix.v; i = getpid(); if (ix_v = getchar() == EOF) ************** * "foo.c", line 5: warning: old-fashioned initialization: use = ***** main() { int i; * long ix.v; i = getpid(); if (ix_v = getchar() == EOF) ************** * "foo.c", line 5: v undefined ***** main() { int i; * long ix.v; i = getpid(); if (ix_v = getchar() == EOF) ************** * "foo.c", line 8: ix_v undefined ***** long ix.v; i = getpid(); * if (ix_v = getchar() == EOF) exit(1); exit(0); } % .fi .SH "SEE ALSO" cc(1), grep(1) .SH AUTHOR Copyright (C) 1985 by North Coast Programming. This program, and any documentation for it, is copyrighted by North Coast Programming. It may be copied for non-commercial use only, provided that any and all copyright notices are preserved. Please report any bugs and/or fixes to: .nf North Coast Programming 6504 Chestnut Road Independence, OH 44131 \&...decvax!cwruecmp!ncoast!bsa ncoast!bsa@Case.CSNet This manual page by ..decvax!mcvax!enea!tut!jty (Jyrki Yli-Nokari), to whom I give many thanks. //E*O*F context.1// echo Possible errors detected by \'wc\' [hopefully none]: temp=/tmp/shar$$ trap "rm -f $temp; exit" 0 1 2 3 15 cat > $temp <<\!!! 97 277 1758 context.1 !!! wc context.1 | sed 's=[^ ]*/==' | diff -b $temp - ---------------------------------- cut here ---------------------------------- -- Brandon Allbery, Unix Consultant -- 6504 Chestnut Road, Independence, OH 44131 decvax!cwruecmp!ncoast!bsa; ncoast!bsa@case.csnet; +1 216 524 1416; 74106,1032 ========================> Trekkies have Warped minds. <=======================