[OS X TeX] Remarks about TeX on Leopard

Herbert Schulz herbs at wideopenwest.com
Sun Nov 4 09:22:24 EST 2007

On Nov 4, 2007, at 8:02 AM, Peter Dyballa wrote:

> Am 04.11.2007 um 14:16 schrieb Bruno Voisin:
>> From the man page of echo:
> Therefore I first made clear that there is no newline to suppress  
> (which in bash variables can cause trouble or make bash do not what  
> I want, and these cases one can foresee).


I thought that by default echo always adds its own new line at the  
end before ``exiting.'' E.g.,

echo Hello ; echo " World"



on separate lines. I think the -n option was meant to suppress this  
newline so a line could be continued; e.g.

echo -n Hello ; echo " World"

prints out

Hello World

all on a single line. I think the -n option is standard in bash but  
not in sh.

There is also an echo command in /bin/ that does accept the -n option  
so you could replace

echo -n ...


/bin/echo -n ...

or use Apple's suggestion of

printf "%s" ...

or change from sh to bash.

Good Luck,

Herb Schulz
(herbs at wideopenwest.com)

------------------------- Helpful Info -------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
List Reminders & Etiquette: http://www.esm.psu.edu/mac-tex/list/

More information about the MacOSX-TeX mailing list