Timeline for How to convert a string to lower case in Bash
Current License: CC BY-SA 4.0
10 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Sep 29, 2021 at 14:51 | comment | added | Walter Tross |
I tried sed 's/./\L&/g' in zsh, but the output is full of Ls...
|
|
Dec 4, 2020 at 10:47 | history | edited | nettux | CC BY-SA 4.0 |
deleted 185 characters in body; deleted 7 characters in body
|
Jun 25, 2019 at 16:35 | comment | added | mmigdol |
Node alternative: node -p "\"$a\".toLowerCase()"
|
|
Mar 6, 2019 at 14:05 | comment | added | inetphantom | I prefer using the dd solution. Please note that you need to be root to get it working | |
Dec 9, 2017 at 13:47 | comment | added | Dudi Boy | I like the sed solution the most, since sed is always ubiquitous. | |
Jan 16, 2016 at 11:45 | comment | added | tripleee |
Do not use! All of the examples which generate a script are extremely brittle; if the value of a contains a single quote, you have not only broken behavior, but a serious security problem.
|
|
Nov 21, 2015 at 17:34 | comment | added | JESii | Hi, @nettux443... I just tried the bash operation again and it still fails for me with the error message "bad substitution". I'm on OSX using homebrew's bash: GNU bash, version 4.3.42(1)-release (x86_64-apple-darwin14.5.0) | |
Nov 20, 2015 at 14:33 | comment | added | nettux | @JESii both work for me upper -> lower and lower-> upper. I'm using sed 4.2.2 and Bash 4.3.42(1) on 64bit Debian Stretch. | |
Aug 30, 2014 at 3:38 | history | edited | Deqing | CC BY-SA 3.0 |
corrected spelling
|
May 14, 2014 at 9:36 | history | answered | nettux | CC BY-SA 3.0 |