mirror of
https://github.com/ruby/setup-ruby.git
synced 2026-09-13 14:34:21 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
01b616c294 | ||
|
|
f010ae485f |
@@ -96,8 +96,6 @@ jobs:
|
||||
* short version like `2.6`, automatically using the latest release matching that version (`2.6.5`)
|
||||
* version only like `2.6.5`, assumes MRI for the engine
|
||||
* engine only like `truffleruby`, uses the latest stable release of that implementation
|
||||
|
||||
|
||||
* `.ruby-version` reads from the project's `.ruby-version` file
|
||||
* `.tool-versions` reads from the project's `.tool-versions` file
|
||||
* If the `ruby-version` input is not specified, `.ruby-version` is tried first, followed by `.tool-versions`
|
||||
|
||||
+7
-1
@@ -3389,6 +3389,7 @@ __webpack_require__.r(__webpack_exports__);
|
||||
const os = __webpack_require__(87)
|
||||
const path = __webpack_require__(622)
|
||||
const core = __webpack_require__(470)
|
||||
const exec = __webpack_require__(986)
|
||||
const io = __webpack_require__(1)
|
||||
const tc = __webpack_require__(533)
|
||||
const rubyBuilderVersions = __webpack_require__(156)
|
||||
@@ -3423,7 +3424,12 @@ async function downloadAndExtract(platform, ruby) {
|
||||
console.log(url)
|
||||
|
||||
const downloadPath = await tc.downloadTool(url)
|
||||
await tc.extractTar(downloadPath, rubiesDir)
|
||||
if (platform.startsWith('windows')) {
|
||||
let args = [ '-xz', '-C', rubiesDir, '-f', downloadPath ]
|
||||
await exec.exec('C:\\Windows\\system32\\tar.exe', args)
|
||||
} else {
|
||||
await tc.extractTar(downloadPath, rubiesDir)
|
||||
}
|
||||
|
||||
return path.join(rubiesDir, ruby)
|
||||
}
|
||||
|
||||
+7
-1
@@ -1,6 +1,7 @@
|
||||
const os = require('os')
|
||||
const path = require('path')
|
||||
const core = require('@actions/core')
|
||||
const exec = require('@actions/exec')
|
||||
const io = require('@actions/io')
|
||||
const tc = require('@actions/tool-cache')
|
||||
const rubyBuilderVersions = require('./ruby-builder-versions')
|
||||
@@ -35,7 +36,12 @@ async function downloadAndExtract(platform, ruby) {
|
||||
console.log(url)
|
||||
|
||||
const downloadPath = await tc.downloadTool(url)
|
||||
await tc.extractTar(downloadPath, rubiesDir)
|
||||
if (platform.startsWith('windows')) {
|
||||
let args = [ '-xz', '-C', rubiesDir, '-f', downloadPath ]
|
||||
await exec.exec('C:\\Windows\\system32\\tar.exe', args)
|
||||
} else {
|
||||
await tc.extractTar(downloadPath, rubiesDir)
|
||||
}
|
||||
|
||||
return path.join(rubiesDir, ruby)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user