-
Notifications
You must be signed in to change notification settings - Fork 8
52 lines (50 loc) · 1.59 KB
/
windows.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: windows
on:
- push
- pull_request
jobs:
build:
runs-on: windows-latest
strategy:
matrix:
ruby:
- "3.2"
- "3.1"
include:
- ruby: "3.0.3"
# On Ruby 3.0, we need to use fiddle 1.0.8 or later to retrieve correct
# error code. In addition, we have to specify the path of fiddle by RUBYLIB
# because RubyInstaller loads Ruby's bundled fiddle before initializing gem.
# See also:
# * https://github.com/ruby/fiddle/issues/72
# * https://bugs.ruby-lang.org/issues/17813
# * https://github.com/oneclick/rubyinstaller2/blob/8225034c22152d8195bc0aabc42a956c79d6c712/lib/ruby_installer/build/dll_directory.rb
ruby-lib-opt: RUBYLIB=%RUNNER_TOOL_CACHE%/Ruby/3.0.3/x64/lib/ruby/gems/3.0.0/gems/fiddle-1.1.0/lib
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install dependencies
run: |
ridk enable
pacman -Sy --noconfirm mingw-w64-x86_64-libmaxminddb
- name: Setup ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler: latest
bundler-cache: true
- name: Check Ruby version
run: |
ruby -v
- name: Add Fiddle 1.1.0
if: ${{ matrix.ruby == "3.0.3" }}
run: gem install fiddle --version 1.1.0
- name: Build
run: |
ridk enable
bundle exec rake compile
- name: Run test
run: |
ridk enable
bundle exec rake test