Skip to content

Commit

Permalink
Add jruby and truffleruby to github actions testing
Browse files Browse the repository at this point in the history
relates to #22
  • Loading branch information
anirbanmu committed Mar 28, 2020
1 parent 0c69f2d commit b44585f
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 10 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/checks.yml
Expand Up @@ -12,6 +12,9 @@ jobs:
- '2.6'
- '2.5'
- '2.4'
- '2.3'
- jruby
- truffleruby
rust:
- 1.42.0
- 1.41.0
Expand All @@ -21,7 +24,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- uses: actions-rs/toolchain@v1
Expand Down Expand Up @@ -67,7 +70,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- name: Generate Gemfile.lock
Expand Down Expand Up @@ -95,7 +98,7 @@ jobs:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- uses: actions-rs/toolchain@v1
Expand Down Expand Up @@ -143,7 +146,7 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- uses: actions-rs/toolchain@v1
Expand Down Expand Up @@ -191,7 +194,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- uses: actions-rs/toolchain@v1
Expand Down Expand Up @@ -243,7 +246,7 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- uses: actions-rs/toolchain@v1
Expand Down Expand Up @@ -295,7 +298,7 @@ jobs:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "${{ matrix.ruby }}"
- uses: actions-rs/toolchain@v1
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/generate_checks_workflow.rb
Expand Up @@ -15,7 +15,7 @@ def deep_stringify_keys(element)
DEFAULT_RUBY_VERSION = '2.7'
DEFAULT_RUST_VERSION = '1.42.0'

RUBY_VERSIONS = Set.new([DEFAULT_RUBY_VERSION, '2.7', '2.6', '2.5', '2.4']).to_a.freeze
RUBY_VERSIONS = Set.new([DEFAULT_RUBY_VERSION, '2.7', '2.6', '2.5', '2.4', '2.3', 'jruby', 'truffleruby']).to_a.freeze
RUST_VERSIONS = Set.new([DEFAULT_RUST_VERSION, '1.42.0', '1.41.0', '1.40.0', '1.39.0', '1.38.0']).to_a.freeze

INSTALL_GEMS_STEPS = [
Expand Down Expand Up @@ -90,7 +90,7 @@ def deep_stringify_keys(element)

INSTALL_RUBY_STEPS = [
{
uses: 'actions/setup-ruby@v1',
uses: 'ruby/setup-ruby@v1',
with: { 'ruby-version': '${{ matrix.ruby }}' }
}
].freeze
Expand Down
13 changes: 12 additions & 1 deletion README.md
Expand Up @@ -4,7 +4,7 @@
[![Gem Version](https://badge.fury.io/rb/str_metrics.svg)](https://rubygems.org/gems/str_metrics)
[![license](https://img.shields.io/github/license/anirbanmu/str_metrics?style=plastic)](LICENSE)

Ruby gem (native extension in Rust) providing implementations of various string metrics. Current metrics supported are: Sørensen–Dice, Levenshtein, Damerau–Levenshtein, Jaro & Jaro–Winkler. Strings that are UTF-8 encodable (convertible to UTF-8 representation) are supported. All comparison of strings is done at the grapheme cluster level as described by [Unicode Standard Annex #29](https://www.unicode.org/reports/tr29/#Grapheme_Cluster_Boundaries); this may be different from many gems that calculate string metrics. Gem should work on Linux, MacOS & Windows.
Ruby gem (native extension in Rust) providing implementations of various string metrics. Current metrics supported are: Sørensen–Dice, Levenshtein, Damerau–Levenshtein, Jaro & Jaro–Winkler. Strings that are UTF-8 encodable (convertible to UTF-8 representation) are supported. All comparison of strings is done at the grapheme cluster level as described by [Unicode Standard Annex #29](https://www.unicode.org/reports/tr29/#Grapheme_Cluster_Boundaries); this may be different from many gems that calculate string metrics. See [here](#known-compatibility) for known compatibility.

## Getting Started
### Prerequisites
Expand All @@ -15,6 +15,17 @@ Install Rust (tested with version `>= 1.38.0`) with:
curl https://sh.rustup.rs -sSf | sh
```

### Known compatibility

#### Ruby
`2.7`, `2.6`, `2.5`, `2.4`, `2.3`, `jruby`, `truffleruby`

#### Rust
`1.42.0`, `1.41.0`, `1.40.0`, `1.39.0`, `1.38.0`

#### Platforms
`Linux`, `MacOS`, `Windows`

### Installation

#### With [`bundler`](https://bundler.io/)
Expand Down

0 comments on commit b44585f

Please sign in to comment.