Files
proxmox/scripts/sync-hybx-sidecars-one-by-one.sh
defiQUG bea1903ac9
Some checks failed
Deploy to Phoenix / deploy (push) Has been cancelled
Sync all local changes: docs, config, scripts, submodule refs, verification evidence
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-21 15:46:06 -08:00

41 lines
928 B
Bash

#!/usr/bin/env bash
# Sync all nine HYBX sidecars one repo at a time. Run from proxmox repo root.
# Usage: bash scripts/sync-hybx-sidecars-one-by-one.sh [--sync]
# --sync: pull before push (default: push only).
set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
cd "$SCRIPT_DIR/.."
REPOS=(
mifos-fineract-sidecar
mt103-hardcopy-sidecar
off-ledger-2-on-ledger-sidecar
securitization-engine-sidecar
card-networks-sidecar
securities-sidecar
flash-loan-xau-sidecar
server-funds-sidecar
docs-for-sidecars
)
SYNC_ARG=""
[[ "${1:-}" == "--sync" ]] && SYNC_ARG="--sync"
ok=0
fail=0
for name in "${REPOS[@]}"; do
echo ""
echo ">>> Syncing: $name"
if bash scripts/push-hybx-sidecars-to-gitea.sh $SYNC_ARG "$name"; then
((ok++)) || true
else
((fail++)) || true
echo " $name failed (exit $?)"
fi
done
echo ""
echo "Result: $ok ok, $fail failed"
[ "$fail" -gt 0 ] && exit 1
exit 0