mirror of
https://github.com/ruby/setup-ruby.git
synced 2026-09-13 14:34:21 +02:00
Fix ruby-builder.js - Windows io.mkdirP("D:\\")
This commit is contained in:
+4
-1
@@ -58790,6 +58790,7 @@ __nccwpck_require__.r(__webpack_exports__);
|
||||
/* harmony export */ "install": () => (/* binding */ install)
|
||||
/* harmony export */ });
|
||||
const os = __nccwpck_require__(2087)
|
||||
const fs = __nccwpck_require__(5747)
|
||||
const path = __nccwpck_require__(5622)
|
||||
const exec = __nccwpck_require__(1514)
|
||||
const io = __nccwpck_require__(7436)
|
||||
@@ -58835,7 +58836,9 @@ async function downloadAndExtract(platform, engine, version, rubyPrefix) {
|
||||
const parentDir = path.dirname(rubyPrefix)
|
||||
|
||||
await io.rmRF(rubyPrefix)
|
||||
await io.mkdirP(parentDir)
|
||||
if (!(fs.existsSync(parentDir) && fs.statSync(parentDir).isDirectory())) {
|
||||
await io.mkdirP(parentDir)
|
||||
}
|
||||
|
||||
const downloadPath = await common.measure('Downloading Ruby', async () => {
|
||||
const url = getDownloadURL(platform, engine, version)
|
||||
|
||||
+4
-1
@@ -1,4 +1,5 @@
|
||||
const os = require('os')
|
||||
const fs = require('fs')
|
||||
const path = require('path')
|
||||
const exec = require('@actions/exec')
|
||||
const io = require('@actions/io')
|
||||
@@ -44,7 +45,9 @@ async function downloadAndExtract(platform, engine, version, rubyPrefix) {
|
||||
const parentDir = path.dirname(rubyPrefix)
|
||||
|
||||
await io.rmRF(rubyPrefix)
|
||||
await io.mkdirP(parentDir)
|
||||
if (!(fs.existsSync(parentDir) && fs.statSync(parentDir).isDirectory())) {
|
||||
await io.mkdirP(parentDir)
|
||||
}
|
||||
|
||||
const downloadPath = await common.measure('Downloading Ruby', async () => {
|
||||
const url = getDownloadURL(platform, engine, version)
|
||||
|
||||
Reference in New Issue
Block a user