Mercurial > hg > toybox
view toys/yes.c @ 188:6a12feedd893
Minor cleanups/tweaks to touch.
author | Rob Landley <rob@landley.net> |
---|---|
date | Fri, 30 Nov 2007 04:37:24 -0600 |
parents | 25447caf1b4b |
children | 30a6db5a95c2 |
line wrap: on
line source
/* vi: set sw=4 ts=4: */ /* * yes.c - Repeatedly output a string. */ #include "toys.h" void yes_main(void) { for (;;) { int i; for (i=0; toys.optargs[i]; i++) { if (i) xputc(' '); xprintf("%s", toys.optargs[i]); } if (!i) xputc('y'); xputc('\n'); } }