From 256e4cd2ce5edba5a28dfd63fd72d1bb02b4685f Mon Sep 17 00:00:00 2001 From: teor Date: Fri, 30 Jun 2023 02:01:51 +1000 Subject: [PATCH] Use a heart image with a compatible licence (#7102) --- zebrad/src/components/tracing/component.rs | 18 +++++++--- zebrad/src/components/tracing/zebra.utf8 | 40 +++++++++++----------- 2 files changed, 33 insertions(+), 25 deletions(-) diff --git a/zebrad/src/components/tracing/component.rs b/zebrad/src/components/tracing/component.rs index 2dff3a157..36a2abaac 100644 --- a/zebrad/src/components/tracing/component.rs +++ b/zebrad/src/components/tracing/component.rs @@ -24,15 +24,23 @@ use super::flame; // Art generated with these two images. // Zebra logo: book/theme/favicon.png -// Heart image: https://commons.wikimedia.org/wiki/File:Heart_coraz%C3%B3n.svg -// (License: CC BY-SA 3.0) +// License: MIT or Apache 2.0 +// +// Heart image: https://commons.wikimedia.org/wiki/File:Love_Heart_SVG.svg +// Author: Bubinator +// License: Public Domain or Unconditional Use // // How to render // -// Convert heart image to PNG (2000px) and run: -// img2txt -W 40 -H 20 -f utf8 -d none Heart_corazón.svg.png > heart.utf8 +// Convert heart image to PNG (2000px): +// curl -o heart.svg https://upload.wikimedia.org/wikipedia/commons/4/42/Love_Heart_SVG.svg +// cargo install resvg +// resvg --width 2000 --height 2000 heart.svg heart.png +// +// Then to text (40x20): +// img2txt -W 40 -H 20 -f utf8 -d none heart.png > heart.utf8 // img2txt -W 40 -H 20 -f utf8 -d none favicon.png > logo.utf8 -// paste -d "\0" favicon.utf8 heart.utf8 > zebra.utf8 +// paste -d "\0" logo.utf8 heart.utf8 > zebra.utf8 static ZEBRA_ART: [u8; include_bytes!("zebra.utf8").len()] = *include_bytes!("zebra.utf8"); /// A type-erased boxed writer that can be sent between threads safely. diff --git a/zebrad/src/components/tracing/zebra.utf8 b/zebrad/src/components/tracing/zebra.utf8 index cb30359a9..18b39c533 100644 --- a/zebrad/src/components/tracing/zebra.utf8 +++ b/zebrad/src/components/tracing/zebra.utf8 @@ -1,20 +1,20 @@ - X@8:::::::@X - @::X:;SX;%8S8@@:X::8 - @:;@8@.S8 ;;t;. XX.;@@;:@ 8; %X X% ;8 - 8:@88 .%@.S@.XS: 888:8 X :: .: X - :;SX XS8;::@X@8::;8t8: 8;;:@ % SS % - @::@ 88:::8 8::88::::::X@ 8::8 S X - @:XS8 ;::::::8.88%8@S88::::8: 8S8:8 X S - ::;8 t8S8::::@St 88SX @SS@8:8S;8S @@:: 8 8 -8:XX %%@@::X% 8: X@ t:8t X ..%t8 ;8:8   -::8t: tX:X8tS 8: :@ ;.8@.X tt888: @8:: @ X -::8S: @:8Xtt% 8: S 8 8S.   .8;::. 88:: 8 8 -::X8 S@8 8:8.@8@8Xt S  .%8;S %8:: : : - ::@8 S .  @:::::::X;@ 8.88S8 @8;:X :: :; - 8:X8X .@:X88:::::::::888 @;:X %88:: t t - @::S 888@8:::::::::8X; 8 8::8 8 8 - X:;S@ tXX8;::::::::S::@8 8;S:8 X. .X - ::8S@ :S88XX@8X: @XX:: :: :: - 8:;%X8.:S t; X8%S:8X tt - X8::8SS8SX8@@X@8;8S:8X - X@8:::::::@XS + X@8:::::::@X  S888@t S888% + @::X:;SX;%8S8@@:X::8 S: .8 @. .@ + @:;@8@.S8 ;;t;. XX.;@@;:@ ; % ; X + 8:@88 .%@.S@.XS: 888:8 8 t% @ + :;SX XS8;::@X@8::;8t8: 8;;:@    + @::@ 88:::8 8::88::::::X@ 8::8 @ 8 + @:XS8 ;::::::8.88%8@S88::::8: 8S8:8 X X + ::;8 t8S8::::@St 88SX @SS@8:8S;8S @@:: 8 8 +8:XX %%@@::X% 8: X@ t:8t X ..%t8 ;8:8   +::8t: tX:X8tS 8: :@ ;.8@.X tt888: @8:: X % +::8S: @:8Xtt% 8: S 8 8S.   .8;::. 88:: % t +::X8 S@8 8:8.@8@8Xt S  .%8;S %8:: 8 8 + ::@8 S .  @:::::::X;@ 8.88S8 @8;:X % % + 8:X8X .@:X88:::::::::888 @;:X %88:: % % + @::S 888@8:::::::::8X; 8 8::8 8 8 + X:;S@ tXX8;::::::::S::@8 8;S:8 S. :t + ::8S@ :S88XX@8X: @XX:: % % + 8:;%X8.:S t; X8%S:8X @ S + X8::8SS8SX8@@X@8;8S:8X S % + X@8:::::::@XS %