Skip to content

Update version to not mark gem as prerelease and add source gem #345

Update version to not mark gem as prerelease and add source gem

Update version to not mark gem as prerelease and add source gem #345

Workflow file for this run

name: Continuous Integration
on:
pull_request:
push:
branches:
- main
- "releases/*"
jobs:
build-lint-test:
strategy:
fail-fast: true
matrix:
# TODO(cretz): Enable Linux ARM. It's not natively supported with setup-ruby (see
# https://github.com/ruby/setup-ruby#supported-platforms and https://github.com/ruby/setup-ruby/issues/577).
# So we need to set ruby-version to 'none' per
# https://github.com/oxidize-rb/actions/tree/main/setup-ruby-and-rust and install Ruby ourselves maybe. See
# https://github.com/ruby/setup-ruby?tab=readme-ov-file#using-self-hosted-runners. The error states:
# Error: The current runner (ubuntu-24.04-arm64) was detected as self-hosted because the platform does not match a GitHub-hosted runner image (or that image is deprecated and no longer supported).
# In such a case, you should install Ruby in the $RUNNER_TOOL_CACHE yourself, for example using https://github.com/rbenv/ruby-build
# You can take inspiration from this workflow for more details: https://github.com/ruby/ruby-builder/blob/master/.github/workflows/build.yml
#
# TODO(cretz): Enable x64-mingw-ucrt if we can figure out Windows issue, see
# https://github.com/temporalio/sdk-ruby/issues/172
os: [ubuntu-latest, macos-latest]
# Earliest and latest supported
rubyVersion: ["3.1", "3.3"]
include:
- os: ubuntu-latest
rubyVersion: "3.3"
checkTarget: true
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup Ruby and Rust
uses: oxidize-rb/actions/setup-ruby-and-rust@v1
with:
ruby-version: ${{ matrix.rubyVersion }}
bundler-cache: true
cargo-cache: true
working-directory: ./temporalio
# Needed for tests currently
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: stable
# Needed because gRPC tools does not have a macOS protoc binary
# currently, see https://github.com/grpc/grpc/issues/25755
- name: Install protoc for mac
if: ${{ matrix.os == 'macos-latest' }}
uses: arduino/setup-protoc@v3
with:
version: "23.x"
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install bundle
working-directory: ./temporalio
run: bundle install
- name: Check generated protos
if: ${{ matrix.checkTarget }}
working-directory: ./temporalio
run: |
bundle exec rake proto:generate
[[ -z $(git status --porcelain lib/temporalio/api) ]] || (git diff lib/temporalio/api; echo "Protos changed" 1>&2; exit 1)
- name: Lint, compile, test Ruby
working-directory: ./temporalio
run: bundle exec rake TESTOPTS="--verbose"