Error using builtin print command in mksh
Eric Blake
eblake@redhat.com
Wed Apr 27 17:23:00 GMT 2016
On 04/27/2016 06:48 AM, leonhard.baumstark@free.fr wrote:
> Hello,
> we are using lots of ksh scripts in mksh. They contain print commands to insert
> separators like ---------------- into text output files. Contrary to Ubuntu's
> ksh this results in the following error message:
>> $ mksh -c "print ---"
> mksh: print: --: unknown option
'print' is not standardized, so you can't expect it to behave portably.
Fix your script to use
printf -- -------
instead, and then you won't have any portability problems, whether on
cygwin or any other platform.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 604 bytes
Desc: OpenPGP digital signature
URL: <http://cygwin.com/pipermail/cygwin/attachments/20160427/59d7083e/attachment.sig>
More information about the Cygwin
mailing list