diff --git a/dist/setup/index.js b/dist/setup/index.js index 9ad3784ea..e3b4d9152 100644 --- a/dist/setup/index.js +++ b/dist/setup/index.js @@ -88749,12 +88749,15 @@ function parseGoVersion(versionString) { exports.parseGoVersion = parseGoVersion; function resolveVersionInput() { let version = core.getInput('go-version'); - const versionFilePath = core.getInput('go-version-file'); + let versionFilePath = core.getInput('go-version-file'); if (version && versionFilePath) { core.warning('Both go-version and go-version-file inputs are specified, only go-version will be used'); } if (version) { - return version; + if (!version.endsWith('go.mod')) { + return version; + } + versionFilePath = version; } if (versionFilePath) { if (!fs_1.default.existsSync(versionFilePath)) {