From 6889314b224870a6b40bfb2aad62a59a555add8e Mon Sep 17 00:00:00 2001 From: Janos <86970079+janosdebugs@users.noreply.github.com> Date: Wed, 28 Jul 2021 09:02:08 +0200 Subject: [PATCH] More testing --- index.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index 458d6b8..6ef4a4d 100644 --- a/index.js +++ b/index.js @@ -17,13 +17,13 @@ async function downloadRelease(octokit, org, repo, release) { console.log("Writing gotestfmt to ./tmp/gotestfmt.tar.gz...") fs.writeFileSync("/tmp/gotestfmt.tar.gz", response.data) console.log("Creating /usr/local/lib/gotestfmt directory...") - fs.mkdirSync("/usr/local/lib/gotestfmt") + execSync("sudo mkdir -p /usr/local/lib/gotestfmt") console.log("Unpacking tar file...") - execSync("cd /usr/local/lib/gotestfmt && tar -xvzf /tmp/gotestfmt.tar.gz") + execSync("cd /usr/local/lib/gotestfmt && sudo tar -xvzf /tmp/gotestfmt.tar.gz") console.log("Removing tarball...") fs.unlinkSync("/tmp/gotestfmt.tar.gz") console.log("Linking gotestfmt...") - fs.symlinkSync("/usr/local/bin/gotestfmt", "/usr/local/lib/gotestfmt/gotestfmt") + execSync("sudo ln -s /usr/local/lib/gotestfmt/gotestfmt /usr/local/bin/gotestfmt") console.log("Successfully set up gotestfmt.") return }