user766353
user766353

Reputation: 537

What is the "/i" flag in sed?

In sed, you can end a command with the flag "/i" (for example, see this other question). This seems to say "more sed commands coming," or something like that, so you can split sed commands in a script. Or maybe not— I can't find any documentation on this flag.

Upvotes: 6

Views: 5397

Answers (1)

user149341
user149341

Reputation:

It's a modifier to the regular expression which makes it case-insensitive. For instance, s/\ XVID//i would replace " xViD" (or any other capitalization of those four letters) with nothing.

Upvotes: 9

Related Questions