Skip to content

Commit 6edc7f9

Browse files
committed
fix: use info instead of notice for version coercion
1 parent 28c08c8 commit 6edc7f9

File tree

4 files changed

+5
-3
lines changed

4 files changed

+5
-3
lines changed

dist/setup_cpp.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.

dist/setup_cpp.js.map

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: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ export function getCompilerInfo(maybeCompiler: string) {
289289
if (semverValid(maybeVersion) !== null) {
290290
return { compiler, version: maybeVersion }
291291
} else {
292-
notice(`Invalid semver version ${maybeVersion} used for the compiler.`)
292+
info(`Invalid semver version ${maybeVersion} used for the compiler.`)
293293
return { compiler, version: maybeVersion }
294294
}
295295
}

src/utils/setup/version.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import semverCompare from "semver/functions/compare"
33
import semverCoerce from "semver/functions/coerce"
44
import semverValid from "semver/functions/valid"
55
import { getExecOutput } from "@actions/exec"
6+
import { info } from "../io/io"
67

78
/**
89
* Gets the specific versions supported by this action compatible with the supplied (specific or minimum) version in
@@ -96,6 +97,7 @@ export function semverCoerceIfInvalid(version: string) {
9697
// find the semver version of an integer
9798
const coercedVersion = semverCoerce(version)
9899
if (coercedVersion !== null) {
100+
info(`Coerced version '${version}' to '${coercedVersion}'`)
99101
return coercedVersion.version
100102
}
101103
} catch (err) {

0 commit comments

Comments
 (0)