diff --git a/packaging/ota/publish-jobs.sh b/packaging/ota/publish-jobs.sh index d5defb54..7b4515df 100755 --- a/packaging/ota/publish-jobs.sh +++ b/packaging/ota/publish-jobs.sh @@ -333,6 +333,14 @@ PY mv "$NEW" "$JOBS" mv "$NEW.sig" "$JOBS.sig" echo "jobs file: $JOBS ($(wc -c < "$JOBS" | tr -d ' ') bytes)" +# Rotation phase 2 (5 October 2026): apps built with the next token read the next folder, so the signed file and its +# signature go to both folders while both exist (the 0.3.6 apps missed a job published to the old folder only). +if [ -n "$DLSITE" ] && [ -f "$HOME/.config/igneum/dl-token.next" ]; then + NEXT_TOKEN="$(tr -d '[:space:]' < "$HOME/.config/igneum/dl-token.next")" + if [ -n "$NEXT_TOKEN" ] && [ -d "$DLSITE/dl/$NEXT_TOKEN" ] && [ "$NEXT_TOKEN" != "$TOKEN" ]; then + cp "$JOBS" "$JOBS.sig" "$DLSITE/dl/$NEXT_TOKEN/" && echo "jobs file mirrored to the next folder" + fi +fi if [ "$DEPLOY" = 1 ]; then [ -n "$DLSITE" ] || { echo "--deploy needs the real downloads folder (no --dest)" >&2; exit 1; }