Skip to content

Commit d046db6

Browse files
committed
Fail clearly for CRuby < 2.6 on macos-arm64
1 parent d4138eb commit d046db6

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

dist/index.js

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

index.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,14 @@ function validateRubyEngineAndVersion(platform, engineVersions, engine, parsedVe
161161
found = latestToFirstVersion.find(v => !common.isHeadVersion(v) && v.startsWith(parsedVersion))
162162
}
163163

164+
// Well known version-platform combinations which do not work:
165+
if (found && engine === 'ruby' && platform.startsWith('macos') && platform.endsWith('arm64') && common.floatVersion(found) < 2.6) {
166+
throw new Error(`CRuby < 2.6 does not support macos-arm64.
167+
Either use a newer Ruby version or use a macOS image running on amd64, e.g., macos-13 or macos-12.
168+
Note that GitHub changed the meaning of macos-latest from macos-12 (amd64) to macos-14 (arm64):
169+
https://github.blog/changelog/2024-04-01-macos-14-sonoma-is-generally-available-and-the-latest-macos-runner-image/`)
170+
}
171+
164172
if (found) {
165173
version = found
166174
} else {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy