aports/data/gitea-theme/APKBUILD

34 lines
947 B
Plaintext
Raw Permalink Normal View History

2020-12-23 21:11:19 +00:00
# Contributor: Alex Denes <caskd@redxen.eu>
# Maintainer: Alex Denes <caskd@redxen.eu>
. ../APKBUILD-data.template
2024-03-30 18:39:11 +00:00
pkgver=2024.01.02.01
2020-12-29 18:30:07 +00:00
pkgrel=0
2020-12-23 21:11:19 +00:00
makedepends="imagemagick"
source="logo.svg"
_customroot="/usr/share/gitea/custom"
2024-03-30 18:39:11 +00:00
_rx_installdir="$_customroot/public/assets/img"
_rx_fperm=444 # Public, static resources
2020-12-23 21:11:19 +00:00
build() {
2024-03-30 18:39:11 +00:00
sizes="180 512"
2020-12-23 21:11:19 +00:00
for i in $sizes; do
msg "Scaling svg to $i"
2022-04-02 12:28:50 +00:00
magick -size "$i"x"$i" logo.svg \( +clone -threshold 101% -fill white -draw 'circle %[fx:int(w/2)],%[fx:int(h/2)] %[fx:int(w/2)],%[fx:80+int(h/2)]' \) -channel-fx '| gray=>alpha' logo-"$i".png
2020-12-23 21:11:19 +00:00
done
}
package() {
rx_install logo-180.png favicon.png
rx_install logo-180.png apple-touch-icon.png
2022-04-01 10:32:21 +00:00
rx_install logo-512.png logo.png
2020-12-23 21:11:19 +00:00
rx_install logo.svg logo.svg
rx_install logo.svg favicon.svg
2020-12-23 21:11:19 +00:00
}
sha512sums="
2022-04-02 12:28:50 +00:00
d706ce4edaeccf6fbcea779a55046a20af136a3b9235e35f84c41e6f0aa7ddcae8fa3568d87e8d2f8be4f799c7cfd9f8b4b0ac653c0b4687d498eda25fc3864b logo.svg
"