2021-07-07 18:20:27 +02:00
|
|
|
# Copyright 1999-2021 Gentoo Authors
|
2020-10-28 19:55:07 +01:00
|
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
|
|
|
|
EAPI=7
|
|
|
|
|
|
|
|
inherit desktop git-r3
|
|
|
|
|
|
|
|
DESCRIPTION="Miscellaneous logos, wallpapers and other artwork from src_prepare group"
|
|
|
|
HOMEPAGE="https://gitlab.com/src_prepare/artwork"
|
|
|
|
EGIT_REPO_URI="https://gitlab.com/src_prepare/artwork"
|
|
|
|
|
|
|
|
RESTRICT="binchecks mirror strip test"
|
|
|
|
LICENSE="CC0-1.0"
|
|
|
|
SLOT="0"
|
|
|
|
|
|
|
|
arr_install() {
|
|
|
|
local IFS=$'\n'
|
|
|
|
local cmd="${1}"
|
|
|
|
local files="${2}"
|
|
|
|
|
|
|
|
if [ -n "${files}" ]; then
|
|
|
|
echo "[F] Found following files for installation:"
|
|
|
|
echo "${files}"
|
|
|
|
local file
|
|
|
|
for file in ${files}; do
|
|
|
|
if [ -f "${file}" ]; then
|
|
|
|
echo "[I] Installing: ${file} (using: ${cmd})"
|
|
|
|
"${cmd}" "${file}"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
src_install() {
|
|
|
|
local src_backgrounds=/usr/share/backgrounds/src_prepare
|
|
|
|
local src_share=/usr/share/src_prepare
|
|
|
|
|
|
|
|
# Wallpapers
|
|
|
|
local wallpapers="$(find . -not -path "./.git/*" | grep -i wallpaper | grep -i -E 'jpg|png')"
|
|
|
|
insinto "${src_backgrounds}"
|
|
|
|
arr_install doins "${wallpapers}"
|
|
|
|
|
|
|
|
# Logos
|
2020-11-27 15:14:57 +01:00
|
|
|
local logos="$(find . -not -path "./.git/*" | grep -i logo | grep -i -E 'jpg|png|svg|xpm')"
|
2020-10-28 19:55:07 +01:00
|
|
|
arr_install doicon "${logos}"
|
|
|
|
|
|
|
|
# XCF sources
|
|
|
|
local xcfs="$(find . -not -path "./.git/*" -type f -name '*.xcf')"
|
|
|
|
insinto "${src_share}"
|
|
|
|
arr_install doins "${xcfs}"
|
|
|
|
|
|
|
|
# Docs / notices
|
|
|
|
local docs="$(find . -not -path './.git/*' -type f -name '*README*')"
|
|
|
|
arr_install dodoc "${docs}"
|
|
|
|
}
|
|
|
|
|
|
|
|
pkg_postinst() {
|
|
|
|
einfo "Contributions are welcome :)"
|
|
|
|
einfo "Repository: https://gitlab.com/src_prepare/artwork"
|
|
|
|
}
|