Skip to content

Commit

Permalink
fix(cd): wait for core library to update on crates.io before publish
Browse files Browse the repository at this point in the history
  • Loading branch information
orhun committed Jul 1, 2021
1 parent 4c7b043 commit e795460
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -164,16 +164,20 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@main
- name: Set the release version
run: echo "RELEASE_VERSION=${GITHUB_REF:11}" >> $GITHUB_ENV
- name: Publish the library
uses: actions-rs/cargo@v1
with:
command: publish
args: |
--manifest-path git-cliff-core/Cargo.toml
--locked --token ${{ secrets.CARGO_TOKEN }}
- name: Wait for 10 seconds
- name: Wait for core library to update
shell: bash
run: sleep 10s
run: |
crate_status="https://raw.githubusercontent.com/rust-lang/crates.io-index/master/gi/t-/git-cliff-core"
until curl -s "$crate_status" | grep -q '"vers":"${{ env.RELEASE_VERSION }}"'; do sleep 5; done;
- name: Publish the binary
uses: actions-rs/cargo@v1
with:
Expand Down

0 comments on commit e795460

Please sign in to comment.