Page MenuHomeFreeBSD

sed.1: provide more information on -I and -i
Needs RevisionPublic

Authored by emaste on Mar 8 2021, 2:14 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 14, 3:16 AM
Unknown Object (File)
Sat, Nov 1, 9:24 PM
Unknown Object (File)
Sun, Oct 26, 11:17 PM
Unknown Object (File)
Sat, Oct 25, 1:27 AM
Unknown Object (File)
Oct 16 2025, 3:27 AM
Unknown Object (File)
Oct 5 2025, 8:23 AM
Unknown Object (File)
Sep 21 2025, 11:59 PM
Unknown Object (File)
Sep 13 2025, 8:28 PM
Subscribers

Details

Reviewers
kevans
tobik
gbe
0mp
Group Reviewers
manpages
Summary

For compatibility with other versions of sed (GNU and other BSDs) there should be no space between -I or -i, and the backup extension. The extension is an optional argument with these other sed versions, and "-I .bak" is interpreted as a no-argument (no backup) -I flag, followed by an invalid command ".bak".

Clarify -I "" as a special case to specify no backup that is not compatible with other sed versions.

PR: 254091

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

emaste requested review of this revision.Mar 8 2021, 2:14 PM
emaste created this revision.
gbe added a subscriber: gbe.

LGTM from manpages. Thanks for working on this PR.

This revision is now accepted and ready to land.Mar 11 2021, 5:57 PM
0mp requested changes to this revision.Apr 18 2021, 1:55 PM
0mp added a subscriber: 0mp.
0mp added inline comments.
usr.bin/sed/sed.1
118

I think that we usually try to avoid "you" in docs.

124

This should probably be:

.Fl i Cm \&"" .

This way "" is stylized as a command modifier.

This revision now requires changes to proceed.Apr 18 2021, 1:55 PM