Mailing List Archive


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

Re: [tlug] Adding text to the beginning of a file



On Sun, Mar 18, 2007 at 12:30:15AM +0900, Edward Wright wrote:
> > export IFS=""
> 
> Hmm. Yeah, it does, but I don't get why. 

A little further checking shows that it only seems to work. Tho I expect
it will "seem to work" just about anywhere you use it :)

Check this:

touch abc def "ghi jkl"
export IFS=$'\n'
for file in `ls`;do echo "file: $file"; done

outputs
file: abc
file: def
file: ghi jkl

export IFS=
for file in `ls`;do echo "file: $file"; done

outputs
file: abc
def
ghi jkl

Ed



Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links