From bf97a710569231dc1079fd5b29ed215cf30d15ec Mon Sep 17 00:00:00 2001 From: chrysn Date: Thu, 12 Sep 2024 11:00:13 +0200 Subject: [PATCH] Generate and check-in icons Checking in icons is not super pretty git practice, but when rendering through GitHub, that's the easiest option --- .icons/app.png | Bin 0 -> 445 bytes .icons/app.png.license | 3 +++ .icons/board.png | Bin 0 -> 868 bytes .icons/board.png.license | 3 +++ .icons/rebuild.py | 23 +++++++++++++++++++++++ 5 files changed, 29 insertions(+) create mode 100644 .icons/app.png create mode 100644 .icons/app.png.license create mode 100644 .icons/board.png create mode 100644 .icons/board.png.license create mode 100644 .icons/rebuild.py diff --git a/.icons/app.png b/.icons/app.png new file mode 100644 index 0000000000000000000000000000000000000000..96ed8464a4e558571924983f50b758afbef65022 GIT binary patch literal 445 zcmV;u0Yd(XP)2!*CFhKcy zelnS))9DC?0Z=R!Yqi=})w9`5Rn>%dL=Xf`(*RT|6#)DF-nZFoR+i<#U_dFY*Xx~5 z$757gjRPo`%g5uf)oSH(x$Sm)xm-AoD-;Tz)ijOcI6}zt`Lu1jR4TcyyV-1(%Vh#U zGMQ{Po3?FxMF8&iyKir|+iJBEMNyKZR4N7F^?G^FhfejW^?Getme>2K7=Xv)F&>Xu zmStI1Q4~c{48!m(!!Xrql~Q^*98A+RP17)pzsru}2!b%5&jC!Q)6Z^7>GgVb9H-mu n0vHa5lu|$Z(^OwY{`I5Y(4(@kd$;VH00000NkvXXu0mjf6<^Im literal 0 HcmV?d00001 diff --git a/.icons/app.png.license b/.icons/app.png.license new file mode 100644 index 0000000..a38f152 --- /dev/null +++ b/.icons/app.png.license @@ -0,0 +1,3 @@ +SPDX-License-Identifier: CC-BY-3.0 +SPDX-License-CopyrightText: delapouite +Original file from https://game-icons.net/1x1/delapouite/keyboard.html diff --git a/.icons/board.png b/.icons/board.png new file mode 100644 index 0000000000000000000000000000000000000000..214013e17f2efcbdba2f79b9e200e1f91036d9d1 GIT binary patch literal 868 zcmV-q1DpJbP)L^-qa=b+NSGiBESyyf zTSV>JM$n=ldw_&(3{-L|ConR|!HS3;leP?@a43jgtC$F*V(wyM@OEF^v-^MN{LcS7 z-^T&?&#>8S0AR6LR4SFiYPHVJ&i-0-b#*m7JpB3j`RzQNPP<&LNF*{gHugscuh+Y> zvZ7Qfe}w@c5{cB-)+%uvpO}~^O|Px3B@zjmrVR$e-Q8V09v>MQ`K^KS^77K}_sbeV zkWeU8R#vvUx|+}DtE;QsZnvDRsHo6rG_q7+7&b64APJhLudlDm%gfi-*HIK*TwMJ4 z_{it;1VO0P>R>QP({wZ%-PqXJ+1c^=e25?jxm+%n%UxVt#9}d{(fI!Up3P=mE|=f$ zPo+`>LD=nflgY$!oJ7ve&F${)K0Q4tN@r+nY+PPmJ~=sw#bP8$G7Qt+-fp+s_xAP* zg@V`X<#`^%u>1S_>FH?zfR>gPf*@o*9*>KnI5RT?07FAV;c%FuD4M4AdObx^!C-J} zYfCOJGn>t+REp!cLZJWvkB^U9t#)Byp{J)u^7ME-larH1qtWel^E|ImC~zDGKecM$^~VcX)W1 zOeSUi{QMllu!o0-nwpx*%F5f@+n1M@VzJoJ(7^M&*=#;LI|Bf4I-SX6Qm4~>^KWi$ z-rwKv?Cd-^IKVKhuC9({S&}3(nT*5X__`sE<8NTvcsw2{T`U$$-$Jj~a~vm2hGA}QZtCmn0f1%M?d@#<00cqW+S&lXYPD8X uRY|h|fXQUSFs!s4f*{@9-71wzl0N`$DT5@!cVPzr0000 +# /// script +# dependencies = ["cairosvg"] +# /// + +import urllib.request +import cairosvg + +game_icons = { + "board": ("lorc", "circuitry"), + "app": ("delapouite", "keyboard"), + } + +for (outname, (author, iconname)) in game_icons.items(): + svg = urllib.request.urlopen(f"https://game-icons.net/icons/ffffff/000000/1x1/{author}/{iconname}.svg").read() + outname = outname + ".png" + cairosvg.svg2png(bytestring=svg, write_to=outname, output_width=20, output_height=20) + with open(outname + ".license", "w") as licensefile: + print("SPDX-License-Identifier: CC-BY-3.0", file=licensefile) + print(f"SPDX-License-CopyrightText: {author}", file=licensefile) + print(f"Original file from https://game-icons.net/1x1/{author}/{iconname}.html", file=licensefile)