diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..cb8ca23 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,22 @@ +name: Publish to crates.io + +on: + release: + types: [created] + +jobs: + publish: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Set up Rust + uses: actions/setup-rust@v1 + with: + rust-version: stable + + - name: Publish to Crates.io + env: + CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} + run: cargo publish