mirror of
https://github.com/redhat-actions/buildah-build.git
synced 2025-06-08 10:01:34 +00:00
Refactor inputs to support docker/metadata-action (#76)
This commit is contained in:
parent
f123b1f960
commit
979e6a6c6e
9 changed files with 142 additions and 23 deletions
11
src/utils.ts
11
src/utils.ts
|
@ -110,3 +110,14 @@ export function getInputList(name: string): string[] {
|
|||
[],
|
||||
);
|
||||
}
|
||||
|
||||
export function isFullImageName(image: string): boolean {
|
||||
return image.indexOf(":") > 0;
|
||||
}
|
||||
|
||||
export function getFullImageName(image: string, tag: string): string {
|
||||
if (isFullImageName(tag)) {
|
||||
return tag;
|
||||
}
|
||||
return `${image}:${tag}`;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue