[xmonad] colourful xterms

Bruce Stephens xmonad at cenderis.demon.co.uk
Thu Jun 4 18:29:17 EDT 2009


Gwern Branwen <gwern0 at gmail.com> writes:

[...]

> Sure, but then he'd need to scale it. $RANDOM outputs between 0 and
> 32767, not 0-100.

OK, in zsh, something like:

    printf %d $((RANDOM/327.67))

Of course, none of these are likely to be as good as just using python
(or some other suitable language).  For example the zsh example's not
likely enough to produce 100.  (Hmm, actually wouldn't hex be just as
good?  In which case a shell-based answer might be adequate (use
printf %02x)?)


More information about the xmonad mailing list