mirror of
https://github.com/actions/setup-go.git
synced 2025-07-20 13:55:14 -06:00
Add checking if the specified file exist
This commit is contained in:
parent
dbe1872ad4
commit
1fefa4e324
2 changed files with 20 additions and 13 deletions
|
@ -120,6 +120,11 @@ function resolveVersionInput(): string {
|
|||
}
|
||||
|
||||
if (versionFilePath) {
|
||||
if (!fs.existsSync(versionFilePath)) {
|
||||
throw new Error(
|
||||
`The specified go version file at: ${versionFilePath} does not exist`
|
||||
);
|
||||
}
|
||||
version = installer.parseGoVersionFile(versionFilePath);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue