-
Notifications
You must be signed in to change notification settings - Fork 216
39 lines (36 loc) · 1.12 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
name: Ruby on Windows
on:
push:
branches:
- master
pull_request: {}
merge_group: {}
jobs:
compile:
runs-on: "windows-latest"
strategy:
fail-fast: false
matrix:
ruby: ['3.2', '3.3', ucrt, mswin]
steps:
- uses: actions/checkout@v4
- name: load ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
# ucrt and mswin have the dev version Ruby.
# It introduce checksum mismatches for bundled gems. So remove them before `bundle install`
- name: Purge gem caches
run: |
ruby -e '
exit if "${{ matrix.ruby }}" != "ucrt" && "${{ matrix.ruby }}" != "mswin"
bundled_gems = Dir.glob("D:/ruby-${{ matrix.ruby }}/lib/ruby/gems/*/cache/*.gem")
.map { |path| File.basename(path, ".gem")[/^(.+)-[^-]+$/, 1] }
system "gem uninstall #{bundled_gems.join(" ")}", exception: true
'
- name: bundle install
run: |
bundle config set without profilers libs
bundle install
- name: compile
run: bundle exec rake compile