mirror of
https://github.com/mwisnowski/mtg_python_deckbuilder.git
synced 2025-12-16 23:50:12 +01:00
fix: restore htmx pagination and seed theme defaults
This commit is contained in:
parent
4f7d39acba
commit
6e9ba244c9
14 changed files with 66 additions and 28227 deletions
|
|
@ -4,7 +4,7 @@ set -e
|
|||
# Seed default config files into /app/config if missing (handles first-run with mounted volume)
|
||||
seed_defaults() {
|
||||
# Ensure base config directory exists
|
||||
mkdir -p /app/config /app/config/card_lists
|
||||
mkdir -p /app/config /app/config/card_lists /app/config/themes
|
||||
|
||||
# Copy from baked-in defaults if targets are missing
|
||||
if [ -d "/.defaults/config" ]; then
|
||||
|
|
@ -20,6 +20,21 @@ seed_defaults() {
|
|||
[ -f "/app/config/card_lists/$base" ] || cp "$f" "/app/config/card_lists/$base" 2>/dev/null || true
|
||||
done
|
||||
fi
|
||||
# Seed theme catalog defaults (e.g., synergy pairs, clusters, whitelist)
|
||||
if [ -d "/.defaults/config/themes" ]; then
|
||||
for f in /.defaults/config/themes/*; do
|
||||
[ -e "$f" ] || continue
|
||||
base=$(basename "$f")
|
||||
dest="/app/config/themes/$base"
|
||||
if [ -d "$f" ]; then
|
||||
if [ ! -d "$dest" ]; then
|
||||
cp -r "$f" "$dest" 2>/dev/null || true
|
||||
fi
|
||||
else
|
||||
[ -f "$dest" ] || cp "$f" "$dest" 2>/dev/null || true
|
||||
fi
|
||||
done
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue