#!/bin/bash # # make-icon.sh # Zyquo Local # # Author: Simon-Pierre Boucher # Mail: contact@spboucher.ai # # SVG → AppIcon.icns + menu bar template PNGs. # Full-detail SVG for ≥64 px, simplified variant baked for 16/32 px. set -euo pipefail cd "$(dirname "$0")/../assets/icon" RSVG=rsvg-convert command -v $RSVG >/dev/null || { echo "rsvg-convert not found (brew install librsvg)"; exit 1; } ICONSET=AppIcon.iconset rm -rf "$ICONSET" && mkdir "$ICONSET" # 16/32 from the simplified variant (16@2x = 32 px also simplified) $RSVG -w 16 -h 16 zyquo-local-simple.svg -o "$ICONSET/icon_16x16.png" $RSVG -w 32 -h 32 zyquo-local-simple.svg -o "$ICONSET/icon_16x16@2x.png" $RSVG -w 32 -h 32 zyquo-local-simple.svg -o "$ICONSET/icon_32x32.png" # ≥64 from the full-detail icon $RSVG -w 64 -h 64 zyquo-local.svg -o "$ICONSET/icon_32x32@2x.png" $RSVG -w 128 -h 128 zyquo-local.svg -o "$ICONSET/icon_128x128.png" $RSVG -w 256 -h 256 zyquo-local.svg -o "$ICONSET/icon_128x128@2x.png" $RSVG -w 256 -h 256 zyquo-local.svg -o "$ICONSET/icon_256x256.png" $RSVG -w 512 -h 512 zyquo-local.svg -o "$ICONSET/icon_256x256@2x.png" $RSVG -w 512 -h 512 zyquo-local.svg -o "$ICONSET/icon_512x512.png" $RSVG -w 1024 -h 1024 zyquo-local.svg -o "$ICONSET/icon_512x512@2x.png" iconutil -c icns "$ICONSET" -o AppIcon.icns rm -rf "$ICONSET" # Menu bar template icon (18 pt @1x/@2x) mkdir -p menubar $RSVG -w 18 -h 18 zyquo-local-template.svg -o menubar/MenuBarIcon.png $RSVG -w 36 -h 36 zyquo-local-template.svg -o menubar/MenuBarIcon@2x.png echo "AppIcon.icns + menubar template generated."