Skip to content

Commit 7506bcd

Browse files
[Issue #108] Overwrite CLI Tools (#115)
* Trying this * Revert "Trying this" This reverts commit 46eab8f. * Put exists check around tools move * Remove directory before copying over it * Reverted indent * Revert additional two spaces
1 parent 0bdb2ca commit 7506bcd

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,9 @@ async function installSdkManager(): Promise<string> {
120120
fs.mkdirSync(path.dirname(desiredLocation), {recursive: true})
121121
// @TODO: use io.mv instead of fs-extra once following issue is resolved:
122122
// https://github.com/actions/toolkit/issues/706
123+
124+
if (fs.existsSync(desiredLocation)) fse.removeSync(desiredLocation)
125+
123126
fse.moveSync(
124127
path.join(cmdlineToolsExtractedLocation, 'cmdline-tools'),
125128
desiredLocation

0 commit comments

Comments
 (0)