Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help with magnus migration #32

Merged
merged 16 commits into from
Sep 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: CI

on:
push:
branches:
- main
- migrate-to-magnus

pull_request:

jobs:
ci:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
ruby: ["2.7", "3.0", "3.1", "head"]
steps:
- uses: actions/checkout@v3

- uses: oxidize-rb/actions/setup-ruby-and-rust@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
cargo-cache: true
cache-version: v1

- name: Run ruby tests
run: bundle exec rake

- name: Lint rust
run: |
cargo clippy || true # consider enabling this once lints are fixed
cargo fmt --check || true # consider enabling this once lints are fixed
20 changes: 12 additions & 8 deletions .github/workflows/gem.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ name: Build and release gem

on:
workflow_dispatch:
push:
branches:
- migrate-to-magnus

jobs:
native_gem:
Expand All @@ -10,23 +13,24 @@ jobs:
strategy:
matrix:
platform:
- x86_64-linux
- x86_64-darwin
- arm64-darwin
- "aarch64-linux"
- "arm64-darwin"
- "x86_64-darwin"
- "x86_64-linux"

steps:
- uses: actions/checkout@v2

- uses: ruby/setup-ruby@v1
- uses: oxidize-rb/actions/setup-ruby-and-rust@main
with:
ruby-version: '3.1'
bundler-cache: true
ruby-version: "3.1"
bundler-cache: false
cargo-cache: true
cargo-vendor: true

- uses: oxidize-rb/cross-gem-action@main
with:
platform: ${{ matrix.platform }}
setup: |
bundle
env: |
RUBY_CC_VERSION=3.1.0:3.0.0:2.7.0

Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ mkmf.log

# Added by cargo
/target
Cargo.lock

# build artifacts
ext/**/target
pkg/
lib/yrb.bundle
build/out
vendor/
target/
Gemfile.lock
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"rust-analyzer.checkOnSave.command": "clippy"
}
Loading