mirror of https://github.com/actions/toolkit
pull/1344/head
parent
9529f35ffd
commit
4272cd6ca1
|
@ -9,8 +9,8 @@ export const {
|
|||
readdir,
|
||||
readlink,
|
||||
rename,
|
||||
rm,
|
||||
rmdir,
|
||||
rm,
|
||||
stat,
|
||||
symlink,
|
||||
unlink
|
||||
|
|
|
@ -127,13 +127,13 @@ export async function rmRF(inputPath: string): Promise<void> {
|
|||
}
|
||||
|
||||
try {
|
||||
const cmdPath = ioUtil.getCmdPath()
|
||||
|
||||
await ioUtil.rm(inputPath, {
|
||||
recursive: true,
|
||||
force: true
|
||||
})
|
||||
|
||||
// const cmdPath = ioUtil.getCmdPath()
|
||||
|
||||
// const p = new Promise(async resolve => {
|
||||
// setTimeout(() => {
|
||||
// resolve('timeout')
|
||||
|
@ -197,12 +197,6 @@ export async function rmRF(inputPath: string): Promise<void> {
|
|||
// Shelling out fails to remove a symlink folder with missing source, this unlink catches that
|
||||
try {
|
||||
if (await ioUtil.exists(inputPath)) {
|
||||
if (await ioUtil.isDirectory(inputPath)) {
|
||||
const files = await ioUtil.readdir(inputPath)
|
||||
for (const file of files) {
|
||||
console.log(`second ioUtil.readdir: ${file}`)
|
||||
}
|
||||
}
|
||||
await ioUtil.unlink(inputPath)
|
||||
}
|
||||
} catch (err) {
|
||||
|
|
Loading…
Reference in New Issue