Bash String to Lower or Upper Case: Difference between revisions
Jump to navigation
Jump to search
(→bash 4) |
(→tr) |
||
Line 3: | Line 3: | ||
=tr= | =tr= | ||
* [[Tr#To_Uppercase|tr to uppercase]] | |||
=awk= | =awk= | ||
<syntaxhighlight lang='bash'> | <syntaxhighlight lang='bash'> |
Revision as of 01:34, 11 December 2019
Internal
tr
awk
echo "${text}" | awk '{print tolower($0)}'
bash 4
sed
echo "${text}" | sed -e 's/\(.*\)/\L\1/'