#!/bin/sh # Copies Base's faces into BaseKit's resources (P8): Timeless Sans, fetched # by `make fonts` (git-ignored: its licence forbids committing it), and DM # Sans, the committed OFL fallback the web uses too. Every build runs this # first. Without Timeless Sans a dev build is set in DM Sans, as the web is; # --release refuses to go on without the pinned file (hack/fonts.sh check). set -eu cd "$(dirname "$0")/../.." fonts=native/apple/Sources/BaseKit/Resources/Fonts timeless=internal/look/static/fonts/timeless/1.094/TimelessSansVF.woff2 dmsans=internal/look/static/fonts/dm-sans/4.004/DMSans-VF.woff2 if [ "${1:-}" = --release ]; then hack/fonts.sh check elif [ -n "${1:-}" ]; then echo "usage: $0 [--release]" >&2; exit 2 fi mkdir -p "$fonts" cp "$dmsans" "$fonts/DMSans-VF.woff2" if [ -f "$timeless" ]; then cp "$timeless" "$fonts/TimelessSansVF.woff2" else rm -f "$fonts/TimelessSansVF.woff2" echo "fonts: no Timeless Sans (make fonts fetches it); this build is set in DM Sans" fi