Skip to content

Commit

Permalink
Publish after all CI passes
Browse files Browse the repository at this point in the history
  • Loading branch information
nyurik committed Jun 3, 2024
1 parent a6c1fb0 commit 508e578
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,6 @@ jobs:
fi
popd
ls -lR target/files
- name: Publish to crates.io
if: startsWith(github.ref, 'refs/tags/')
run: cargo publish
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
- name: Publish
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
Expand Down Expand Up @@ -175,3 +170,15 @@ jobs:
files: 'target/files/*'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

publish:
name: Publish to crates.io
if: startsWith(github.ref, 'refs/tags/')
needs: [ test, msrv, build, cross-build ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Publish to crates.io
run: cargo publish
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}

0 comments on commit 508e578

Please sign in to comment.