mirror of
https://github.com/GoTestTools/gotestfmt-action.git
synced 2026-02-18 13:41:47 +00:00
Properly log GOOS detection
Signed-off-by: Yuri Norwood <106889957+norwd@users.noreply.github.com>
This commit is contained in:
parent
56245aa167
commit
5f6ce583a3
1 changed files with 8 additions and 2 deletions
10
index.js
10
index.js
|
|
@ -81,7 +81,7 @@ async function downloadGofmt(octokit, version, versionPrefix, os, org, repo, tok
|
||||||
async function determineOS() {
|
async function determineOS() {
|
||||||
const uname = execSync("uname")
|
const uname = execSync("uname")
|
||||||
|
|
||||||
os = uname.toString().trim().toLowerCase()
|
let os = uname.toString().trim().toLowerCase()
|
||||||
if (os.indexOf("msys_nt") === 0)
|
if (os.indexOf("msys_nt") === 0)
|
||||||
{
|
{
|
||||||
os = "windows";
|
os = "windows";
|
||||||
|
|
@ -93,7 +93,13 @@ async function determineOS() {
|
||||||
}
|
}
|
||||||
|
|
||||||
async function determineGOOS() {
|
async function determineGOOS() {
|
||||||
return process.env.GOOS;
|
const goos = process.env.GOOS;
|
||||||
|
|
||||||
|
if (goos) {
|
||||||
|
console.log(`Running on GOOS '${goos}'`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return goos;
|
||||||
}
|
}
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue