2025-09-26 03:53:54 +02:00
|
|
|
#!/bin/sh -e
|
2025-11-17 15:52:30 +01:00
|
|
|
|
2026-05-22 21:15:31 +02:00
|
|
|
# SPDX-FileCopyrightText: Copyright 2026 Eden Emulator Project
|
2025-09-26 03:53:54 +02:00
|
|
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
2025-11-17 15:52:30 +01:00
|
|
|
|
2025-09-26 03:53:54 +02:00
|
|
|
which optipng || exit
|
2025-11-17 15:52:30 +01:00
|
|
|
NPROC=$(nproc 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null || echo 4)
|
|
|
|
|
|
|
|
|
|
# shellcheck disable=SC2038
|
|
|
|
|
find . -type f -iname '*.png' | xargs -P "$NPROC" -I {} optipng -o7 {}
|
2026-11-01 21:45:45 +01:00
|
|
|
|
|
|
|
|
which svgo || exit
|
|
|
|
|
|
|
|
|
|
# shellcheck disable=SC2038
|
|
|
|
|
find . -type f -iname '*.svg' | xargs -P "$NPROC" -I {} svgo {}
|