diff --git a/dist/index.js b/dist/index.js index 85b33b6e0..be70c1e71 100644 --- a/dist/index.js +++ b/dist/index.js @@ -65054,10 +65054,14 @@ async function downloadAndExtract(platform, engine, version, rubyPrefix) { function getDownloadURL(platform, engine, version) { let builderPlatform = platform - if (platform.startsWith('windows-')) { + if (platform.startsWith('windows-') && os.arch() === 'x64') { builderPlatform = 'windows-latest' } else if (platform.startsWith('macos-')) { - builderPlatform = 'macos-latest' + if (os.arch() === 'x64') { + builderPlatform = 'macos-latest' + } else if (os.arch() === 'arm64') { + builderPlatform = 'macos-13-arm64' + } } if (common.isHeadVersion(version)) { diff --git a/ruby-builder.js b/ruby-builder.js index 8e7f46665..b71483aa0 100644 --- a/ruby-builder.js +++ b/ruby-builder.js @@ -101,10 +101,14 @@ async function downloadAndExtract(platform, engine, version, rubyPrefix) { function getDownloadURL(platform, engine, version) { let builderPlatform = platform - if (platform.startsWith('windows-')) { + if (platform.startsWith('windows-') && os.arch() === 'x64') { builderPlatform = 'windows-latest' } else if (platform.startsWith('macos-')) { - builderPlatform = 'macos-latest' + if (os.arch() === 'x64') { + builderPlatform = 'macos-latest' + } else if (os.arch() === 'arm64') { + builderPlatform = 'macos-13-arm64' + } } if (common.isHeadVersion(version)) {