Skip to content

s/// replacement: implement the \U \L \u \l \E case-conversion escapes #540

Description

@sylvestre

GNU sed supports case-conversion escapes in the replacement text of s///. None of them work in uutils sed today.

$ echo "abc def" | sed 's/b\(.*\)/\U&/'
script uutils sed GNU sed 4.9
s/b\(.*\)/\U&/ aUbc def aBC DEF
s/b\(.*\)/\u&/ aubc def aBc def
s/b\(.*\)/\L&/ a\Lbc def abc def
s/b\(.*\)/\l&/ a\lbc def abc def
s/b\(.*\)/\E&/ a\Ebc def abc def

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions