Split string by newline and space in Bourne shell
        Posted  
        
            by l0b0
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by l0b0
        
        
        
        Published on 2010-05-27T15:55:55Z
        Indexed on 
            2010/05/27
            16:01 UTC
        
        
        Read the original article
        Hit count: 414
        
shell
|bourne-shell
I'm currently using the following to split a file into words - Is there some quicker way?
while read -r line
do
    for word in $line
    do
        words="${words}\n${word}"
    done
done
© Stack Overflow or respective owner