freebsd-skq/usr.bin/sed
Juli Mallett 839af0c103 Add a -i option to sed(1) to do inplace editing, to give us an alternative to
Perl for such things.  The key difference to Perl is that a backup extension
*MUST* be specified, because on one hand it isn't recommended to have options
which optionally take a parameter, and on the other hand, it'd be slightly
unpleasent to implement proper handling for that.

The difference between this and the version posted to developers@ is that it
does handle multiple files in argv after the getopt(3) handling "correctly",
in that the inplace editing-specific code has been moved out to a function,
and that function is used beyond the first file in our linked list.

This option has been documented as FreeBSD-specific in the manpage.

Reviewed by:	developers@ (got feedback from: des, fanf, sobomax, roberto,
		obrien)
MFC after:	1 week
2002-05-07 18:32:18 +00:00
..
TEST
compile.c Fix an ages-old bug in sed(1), which resulted in the absolutely valid 2002-04-12 19:46:05 +00:00
defs.h
extern.h remove __P 2002-03-22 01:42:45 +00:00
main.c Add a -i option to sed(1) to do inplace editing, to give us an alternative to 2002-05-07 18:32:18 +00:00
Makefile Remove NO_WERRORs and WARNS=n's. To be revisited after GCC3. 2002-02-08 23:07:37 +00:00
misc.c WARNS=2 partial fix; use NO_WERROR to protect against some hard-to-fix warnings. 2001-12-12 23:20:16 +00:00
POSIX
process.c Fix sed(1) in the case where a last line is specified and hold space is not 2002-04-07 02:29:56 +00:00
sed.1 Add a -i option to sed(1) to do inplace editing, to give us an alternative to 2002-05-07 18:32:18 +00:00