← back to Wallco Ai
Add publish-ready-batch.sh: curator-force-publish the 18 census-vetted designs (both tables + allow_override + tag), re-vets in WHERE, rebuilds snapshot, prints deploy — Steve runs it
8a607a0b937a6e4265cb56200e084750357d98c6 · 2026-06-01 13:33:16 -0700 · Steve Abrams
Files touched
A scripts/publish-ready-batch.sh
Diff
commit 8a607a0b937a6e4265cb56200e084750357d98c6
Author: Steve Abrams <steve@designerwallcoverings.com>
Date: Mon Jun 1 13:33:16 2026 -0700
Add publish-ready-batch.sh: curator-force-publish the 18 census-vetted designs (both tables + allow_override + tag), re-vets in WHERE, rebuilds snapshot, prints deploy — Steve runs it
---
scripts/publish-ready-batch.sh | 73 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 73 insertions(+)
diff --git a/scripts/publish-ready-batch.sh b/scripts/publish-ready-batch.sh
new file mode 100755
index 0000000..2c9cd98
--- /dev/null
+++ b/scripts/publish-ready-batch.sh
@@ -0,0 +1,73 @@
+#!/usr/bin/env bash
+# publish-ready-batch.sh — curator-force-publish a vetted set of designs.
+#
+# Generated 2026-06-01 from UNPUBLISHED-CENSUS-2026-06-01.md (the 18 clean+TIF
+# publish-ready designs). RUN THIS YOURSELF — it writes to the local catalog.
+# It does NOT deploy to prod (it prints the deploy command for you to run).
+#
+# What it does, for each id that STILL passes the publish-ready gate:
+# - is_published=TRUE on BOTH all_designs AND spoon_all_designs (snapshot reads spoon)
+# - appends the 'curator-force-publish' tag (so passesAestheticGate keeps it)
+# - wraps in SET LOCAL settlement.allow_override (so the PG settlement trigger no-ops)
+# - re-asserts the gate in the WHERE clause, so a stale/bad id CANNOT slip through
+# - rebuilds data/designs.json
+# - prints (does NOT run) ./deploy-kamatera.sh
+#
+# Edit IDS to your curated pick before running.
+
+set -euo pipefail
+export PGHOST=/tmp PGUSER=stevestudio2 PGDATABASE=dw_unified
+STAMP="curator-force-publish $(date +%Y-%m-%d)"
+
+# ── The 18 census-vetted publish-ready ids. Trim to your pick. ──
+IDS=(13612 33321 41525 41528 41534 20321 35269 32148 18564 18563 23342 11577 23607 33577 15052 15053 24359 23173)
+
+ARR="{$(IFS=,; echo "${IDS[*]}")}"
+echo "Requested ${#IDS[@]} ids: ${IDS[*]}"
+read -r -p "Proceed to force-publish the ones that still pass the gate? [y/N] " ok
+[[ "$ok" == "y" || "$ok" == "Y" ]] || { echo "aborted."; exit 1; }
+
+psql -v ON_ERROR_STOP=1 -X <<SQL
+BEGIN;
+SET LOCAL settlement.allow_override = 'true';
+
+CREATE TEMP TABLE _pub ON COMMIT DROP AS
+ SELECT id FROM all_designs
+ WHERE id = ANY('${ARR}'::int[])
+ AND user_removed IS NOT TRUE
+ AND needs_fixing_at IS NULL
+ AND settlement_verdict IN ('OK','BLEED_GHOST_OK')
+ AND (notes IS NULL OR notes NOT LIKE '%EDGES_FAIL%')
+ AND COALESCE(tif_path,'') <> '';
+
+UPDATE all_designs a SET
+ is_published = TRUE,
+ tags = array_remove(COALESCE(a.tags, '{}'::text[]), 'curator-force-publish') || ARRAY['curator-force-publish']::text[],
+ notes = COALESCE(a.notes,'') || ' | ${STAMP}'
+ WHERE a.id IN (SELECT id FROM _pub);
+
+UPDATE spoon_all_designs s SET
+ is_published = TRUE,
+ tags = array_remove(COALESCE(s.tags, '{}'::text[]), 'curator-force-publish') || ARRAY['curator-force-publish']::text[],
+ notes = COALESCE(s.notes,'') || ' | ${STAMP}'
+ WHERE s.id IN (SELECT id FROM _pub);
+
+\echo '--- publishing these ids (passed the gate): ---'
+SELECT id FROM _pub ORDER BY id;
+\echo '--- requested-but-SKIPPED (failed the gate): ---'
+SELECT unnest('${ARR}'::int[]) EXCEPT SELECT id FROM _pub;
+COMMIT;
+SQL
+
+echo
+echo "=== CANARY: confirm published + settlement still clean ==="
+psql -tAc "SELECT id, is_published, settlement_verdict FROM all_designs WHERE id = ANY('${ARR}'::int[]) ORDER BY id;"
+
+echo
+echo "=== Rebuilding data/designs.json snapshot ==="
+python3 scripts/refresh_designs_snapshot.py
+
+echo
+echo "✅ Local catalog + snapshot updated. To go live on wallco.ai, run the deploy yourself:"
+echo " ./deploy-kamatera.sh"
+echo " (deploy ships designs.json + reloads pm2; room/generated dirs stay prod-authored per .deploy.conf excludes.)"
← 05eafc2 Add unpublished-designs census 2026-06-01: 40,107 unpublishe
·
back to Wallco Ai
·
Redirect /api/design/{null,undefined,NaN} home too (belt-and 66f0082 →