help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] Substring Replacement


From: Richard Taubo
Subject: Re: [Help-bash] Substring Replacement
Date: Fri, 30 May 2014 21:02:04 +0200

On May 30, 2014, at 8:55 PM, Eric Blake <address@hidden> wrote:

> On 05/30/2014 12:08 PM, Richard Taubo wrote:
>> On May 30, 2014, at 6:51 PM, Greg Wooledge <address@hidden> wrote:
>>> On Fri, May 30, 2014 at 06:34:47PM +0200, Richard Taubo wrote:
>>>> If you are forced to run everything on one line without using variables, 
>>>> how
>>>> could one accomplish this, e.g:
>>>>    echo "abcABC123ABCabc" | echo ${????//abc/xyz}
>>> 
>>> echo "xyzABC123ABCxyz"
>>> 
>>> Now, what are you REALLY trying to do?
>> 
>> I have solution working like this (thanks to input from this list earlier):
>> while IFS= read -r -d "" path; do
>> echo -n "<li><ul>"
> 
> 'echo -n' is non-portable, you should really get in the habit of using
> printf instead.

That is actually why I make this code, as the final product will hopefully help
me to remember things like this. :-)

Thanks!

Best regards,
Richard Taubo


reply via email to

[Prev in Thread] Current Thread [Next in Thread]