Skip to content

Commit

Permalink
ci(bg-publish): fine-grained retry
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelfig committed Aug 19, 2024
1 parent c4520c5 commit 8da1321
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions scripts/registry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,8 @@ publish() {

# Publish the packages to our local service.
# without concurrency until https://github.com/Agoric/agoric-sdk/issues/8091
yarn lerna publish --concurrency 1 prerelease --exact \
--dist-tag="$DISTTAG" --preid=dev \
--no-push --no-git-reset --no-git-tag-version --no-verify-access --yes

# Convention used in Endo
yarn lerna run clean:types
yarn lerna version --concurrency 1 prerelease --exact \
--preid=dev --no-push --no-git-tag-version --yes

# Change any version prefices to an exact match, and merge our versions.
VERSIONSHASH=$(jq --slurpfile versions <(popd > /dev/null && git cat-file blob "$VERSIONSHASH") \
Expand All @@ -91,6 +87,17 @@ publish() {
| (popd > /dev/null && git hash-object -w --stdin))

git commit -am "chore: update versions"

while ! yarn lerna publish from-package \
--dist-tag="$DISTTAG" --no-git-reset --no-verify-access --yes; do
echo 1>&2 "Retrying publish..."
sleep 5
done
git reset --hard HEAD

# Convention used in Endo
yarn lerna run clean:types

git checkout "$prior"
popd
done
Expand Down

0 comments on commit 8da1321

Please sign in to comment.