Skip to content

Commit a7439cf

Browse files
committed
Add support for macos-12
1 parent b9675e1 commit a7439cf

File tree

4 files changed

+17
-7
lines changed

4 files changed

+17
-7
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18-
os: [ ubuntu-18.04, ubuntu-20.04, macos-10.15, macos-11.0, windows-2019, windows-2022 ]
18+
os: [ ubuntu-18.04, ubuntu-20.04, macos-10.15, macos-11, macos-12, windows-2019, windows-2022 ]
1919
ruby: [ '1.9', '2.0', '2.1', '2.2', '2.3', '2.4', '2.5', '2.6', '2.7', '3.0', '3.1', ruby-head, jruby, jruby-head, truffleruby, truffleruby-head, truffleruby+graalvm, truffleruby+graalvm-head ]
2020
include:
2121
- { os: ubuntu-22.04, ruby: '3.1.0' }

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ The action works on these [GitHub-hosted runners](https://help.github.com/en/act
3939

4040
| Operating System | Recommended | Other Supported Versions |
4141
| ----------- | -------- | -------- |
42-
| Ubuntu | `ubuntu-latest` (= `ubuntu-20.04`) | `ubuntu-18.04` |
43-
| macOS | `macos-latest` (= `macos-10.15`) | `macos-11.0` |
42+
| Ubuntu | `ubuntu-latest` (= `ubuntu-20.04`) | `ubuntu-18.04`, `ubuntu-22.04` (beta, only `ruby: 3.1 - head`) |
43+
| macOS | `macos-latest` (= `macos-11`) | `macos-10.15`, `macos-12` (beta) |
4444
| Windows | `windows-latest` (= `windows-2022`) | `windows-2019` |
4545

4646
On `ubuntu-22.04` (beta), only `ruby: 3.1 - head` are supported, due to Ubuntu 22.04 only supporting OpenSSL 3.

common.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ export const supportedPlatforms = [
103103
'ubuntu-20.04',
104104
'ubuntu-22.04',
105105
'macos-10.15',
106-
'macos-11.0',
106+
'macos-11',
107+
'macos-12',
107108
'windows-2019',
108109
'windows-2022',
109110
]
@@ -118,7 +119,11 @@ export function getVirtualEnvironmentName() {
118119

119120
match = imageOS.match(/^macos(\d{2})(\d+)?/) // e.g. macos1015, macos11
120121
if (match) {
121-
return `macos-${match[1]}.${match[2] || '0'}`
122+
if (match[2]) {
123+
return `macos-${match[1]}.${match[2]}`
124+
} else {
125+
return `macos-${match[1]}`
126+
}
122127
}
123128

124129
match = imageOS.match(/^win(\d+)/) // e.g. win19

dist/index.js

Lines changed: 7 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)