Skip to content

fix: added build step #8

fix: added build step

fix: added build step #8

Workflow file for this run

name: Publish packages
on:
push:
tags:
- '*'
jobs:
rubygems:
runs-on: ubuntu-latest
environment: packages
permissions:
id-token: write
defaults:
run:
shell: bash
working-directory: build/ruby
steps:
# Set up
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.2.2'
- name: Install gems
run: bundle install
- name: Set version
run: bundle exec rake release:version[${{ github.ref_name }}]
- name: Generate ruby
run: bundle exec rake generate_ruby:all
# Release
- uses: rubygems/[email protected]
- name: Publish gem
run: bundle exec rake release:rubygem_push
- name: Wait for release
run: gem exec rubygems-await pkg/*.gem
crates:
runs-on: ubuntu-latest
environment: packages
defaults:
run:
shell: bash
working-directory: build/rust
steps:
# Set up
- uses: actions/checkout@v4
- name: Setup rust
run: rustup update --no-self-update stable
- name: Install protoc
run: curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v28.0-rc1/protoc-28.0-rc-1-linux-x86_64.zip && unzip protoc-28.0-rc-1-linux-x86_64.zip -d ${{ runner.temp }}/proto && chmod +x ${{ runner.temp }}/proto/bin/protoc && ${{ runner.temp }}/proto/bin/protoc --version
- name: Set version
run: sed -i "s/version = \"0.0.0\"/version = \"${{ github.ref_name }}\"/" Cargo.toml
- name: Cargo Login
run: cargo login ${{secrets.CARGO_REGISTRY_TOKEN}}
- name: Build crate
run: PATH=${{ runner.temp }}/proto/bin:$PATH cargo build
env:
RUST_BACKTRACE: 'full'
# Release
- name: Publish crate
run: cargo publish --allow-dirty