[Toybox] How can I contribute

Jarno Mäkipää jmakip87 at gmail.com
Thu Oct 17 11:33:29 PDT 2019


On Thu, Oct 17, 2019 at 1:27 AM Rob Landley <rob at landley.net> wrote:
>
> On 10/14/19 3:07 PM, Denys Nykula wrote:
> >> saw one of the Toybox talks and wanted to see how I could contribute
> >
> > Completing landley.net/toybox/cleanup.html on toys/pending/{dhcp,route}.c
> > to help them out of pending would be most demanded I think.
>
> That's kind of a high bar, though. :)
>
> Right now toys/posix/ls.c only puts one space between filenames in -C or -x mode
> (which is the default output), and I have a todo item to increase that to 2
> spaces (which is what other implementations do). The reason is I misunderstood
> how unicode worked and it turns out combining characters don't come _after_ the
> character they combine with but before, which means a filename that ends with a
> combining character will attach to the space after the filename, and thus make
> two filenames visually run together unless you have a two space gap. The loop
> that needs adjusting is probably the one starting around line 401, I don't
> _think_ tests/ls.test cares (since it has to pass with TEST_HOST and the host
> version generally uses different spacing anyway), but make sure that still passes.

If terminal emulator behaves correctly, such as UXTerm/Xterm does.
Combining chars dont render in space after, but on same area as
previous char. So 'ls' implementation even with on space only between
filenames are readable. That been said most other terminals dont
render them correctly. I tested this on xterm, uxterm, st, alacritty,
termite, terminator.... (I have lots of terminals installed because i
were testing CSI escapes for vi)

with terminator even the two spaces are not enough between zalgo text
filenames... :)

but long story short this problem is mostly terminal emulators
problem, but having 2 spaces between filenames brings consistency with
other implementations anyway.

-Jarno




>
> Or, I just taught xargs to ignore -P but it would be nice if somebody actually
> implemented that instead of ignoring it.
>
> Rob
> _______________________________________________
> Toybox mailing list
> Toybox at lists.landley.net
> http://lists.landley.net/listinfo.cgi/toybox-landley.net



More information about the Toybox mailing list