From 2a81ffd2a5b3da64eef04541509a329432c1b463 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Thu, 6 Apr 2023 15:01:33 +0200 Subject: fixed hextorgb --- bin/common/hextorgb | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/bin/common/hextorgb b/bin/common/hextorgb index e70040e..63fcbbc 100755 --- a/bin/common/hextorgb +++ b/bin/common/hextorgb @@ -1,8 +1,7 @@ #!/usr/bin/env sh -cat /dev/stdin | - tr -d '#' | +tr -d '#' | tr '[:lower:]' '[:upper:]' | - sed -r 's/([0-9A-F]{2})/1n/g ; i ibase=16' | + sed 's/\([0-9A-F]\{2\}\)/\1\n/g;iibase=16' | bc | - tr 'n' ',' | + tr '\n' ',' | sed 's/.$// ; s/.*/rgb(&)/' -- cgit v1.2.3