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
F132349191: D29128.diff
Thu, Oct 16, 3:27 AM
Unknown Object (File)
Sun, Oct 5, 8:23 AM
Unknown Object (File)
Sun, Sep 21, 11:59 PM
Unknown Object (File)
Sep 13 2025, 8:28 PM
Unknown Object (File)
Sep 12 2025, 7:28 PM
Unknown Object (File)
Sep 8 2025, 1:19 PM
Unknown Object (File)
Sep 6 2025, 6:59 PM
Unknown Object (File)
Aug 14 2025, 5:55 AM
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