mirror of
https://github.com/Azure/setup-helm.git
synced 2025-11-07 13:06:56 +00:00
append v to version incase it does not already include
This commit is contained in:
parent
1a980ffbb5
commit
5801d81e70
2 changed files with 5 additions and 0 deletions
|
|
@ -118,6 +118,9 @@ function run() {
|
|||
if (version.toLocaleLowerCase() === 'latest') {
|
||||
version = yield getStableHelmVersion();
|
||||
}
|
||||
else if (!version.toLocaleLowerCase().startsWith('v')) {
|
||||
version = 'v' + version;
|
||||
}
|
||||
let cachedPath = yield downloadHelm(version);
|
||||
try {
|
||||
if (!process.env['PATH'].startsWith(path.dirname(cachedPath))) {
|
||||
|
|
|
|||
|
|
@ -110,6 +110,8 @@ async function run() {
|
|||
let version = core.getInput('version', { 'required': true });
|
||||
if (version.toLocaleLowerCase() === 'latest') {
|
||||
version = await getStableHelmVersion();
|
||||
}else if(!version.toLocaleLowerCase().startsWith('v')){
|
||||
version = 'v' + version;
|
||||
}
|
||||
|
||||
let cachedPath = await downloadHelm(version);
|
||||
|
|
|
|||
Loading…
Reference in a new issue