magic-bytes 0.1.1

Network magic bytes for Bitcoin, Litecoin, Namecoin and Dogecoin.
Documentation
name: "Publish packages"

on:
  release:
    types:
      - created
    tags:
      - "v[0-9]+(\\.[0-9]+)*"

jobs:
  publish:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Install latest stable
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: stable
          override: true
      - name: Cargo publish
        # To have it work you need to set CARGO_REGISTRY_TOKEN environnement variable
        run: |
          export VERSION=${{ github.event.release.tag_name }}
          sed -i "s/0.0.0/${VERSION:1}/g" Cargo.toml
          cat Cargo.toml
          cargo publish --allow-dirty
        env:
           CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}